I have a script that lets users join a mailing list. When they join, it auto-sends them a confirmation with and unsubscribe link at the bottom. This link is dynamically appeneded to include their unique email address ($address) at the end. I am having trouble getting the link to behave like a link. It should show "Click here to be removed from the mailing list." while linking to "http://foo.com/optout.php3?address=$address&delete=yes". The way the code is now, in the confirmation email the output is the raw source code for the link from <a href=...> to <a/>. It is appending to $address properly, but how do i get it to show the link instead of the code that should create the link. Here's what i'm using:
//define the opt-out link.
$link = "http://foo.com/optout.php3?address=$address&delete=yes";
$optout = "<a href=".$link."> Click here to be removed from the mailing list.</a>";
//define the footer
$footer = "This subscription request originated from IP address " . $ip . " on " . $orgdate . "\n\n\n" . $optout;
//send confirmation email
if(@mail($address, SUBJECT, $body, $footer, "From: " . SENDER)){
$message = "Thank you. You will receive a confirmation email soon to verify your subscription";
}
Thanks in advance.