Jump to content

Emailing links problem


vinhbao

Recommended Posts

I am having trouble get links to email when the Link Text does not match the link.

 

<a href=\"http://mysite.org/?upfriday.php&e=$email&v=$v&r=no\">I do not need a ride this Friday</a>

 

Just prints the text with no link, while:

 

<a href=\"http://mysite.org/?upfriday.php&e=$email&v=$v&r=no\">http://mysite.org/?upfriday.php&e=$email&v=$v&r=no</a>

 

Sends the link just fine.

 

Is there a workaround for this? Or is this just a limitation of PHP?

 

The thing is that I want to put 3 options in each email... each of which sends a different response to a script that will enter their response into the database. I'm afraid if the links are this long and non-descriptive, it will confuse my users.

 

Thanks for any help.

Link to comment
Share on other sites

Are you sure you're sending an html formatted email? It sounds like the email is being sent in plain text, and the values in the tags are simply being suppressed by the email client.

 

here is the relevant section: (If I'm not mistaken I copied this from you earlier today.... :-) I have learned a ton from you without even having to talk to you.

 

//set for HTML email

$headers  = 'MIME-Version: 1.0' . "\r\n";

$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";

$headers .= 'From: VNAG RIDES <rides@mysite.org>' . "\r\n";

 

if(mail($to,$subject,$message,$headers)) {

echo "Account is activated.";

} else {

echo "Something went wrong.";

}

 

Link to comment
Share on other sites

I believe I have found the problem. The email I set up as a test was a webmail account that apparently doesn't support HTML mail. Well, the benefit of find this out is that I can make sure to take this into account for those who don't get HTML emails :-)

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.