Hi PHP builder?
I want to run a PHP script that calls virtual greeting card. The php script normally runs fine after send email. But this is the important thing. The sendmail script have problems with long URLs at mailbox like the one above.
and, it's not
a clickable link after receiver got email:
so, I have to write
http://mydomain/virtualcard/pickup.php3 and use the following
claim number:
cf406eef042e5e55b2c3
So, I have to make pickup id, then user can use to get their card at.
Is there a way to pass this problem, I want receiver's email to be clickable link.
This is a part view of the sendemail.php3 script:
// GENERATE A CARD ID
$random = md5 (uniqid (""));
$unique = substr ("$random", 0, 20);
// ADD DB SLASHES
$htext = addslashes("$htext");
$message = addslashes("$message");
$sname = addslashes("$sname");
$smail = addslashes("$smail");
$rname = addslashes("$rname");
$rmail = addslashes("$rmail");
// INSERT DATA
mysql_connect($host,$user,$password);
@mysql_select_db("$db") or die("Unable to open database");
$query = "insert into $table (id, pic, sound, pbcolor, hbcolor, htcolor, hfont, htext, mbcolor, mtcolor, mfont, message, sname, smail, rname, rmail, pickup_id, date) values ('','$pic','$sound','$pbcolor','$hbcolor','$htcolor','$hfont','$htext','$mbcolor','$mtcolor','$mfont','$message','$sname','$smail','$rname','$rmail','$unique', now())";
$result = mysql_query($query);
// SEND THE MAIL
$mailsender = "From: $sname <$smail>";
$subject = "A friend has sent you a Virtual Greeting Card from $sitename";
$mailmessage = "Hello $rname!\n\n $sname <$smail> has sent you a virtual greeting card via $sitename\n\n
You can get your card at $installpath/pickup.php3 and use the following claim number:\n
$unique";
mail($rmail, $subject, $mailmessage, $mailsender);
?>
<DIV ALIGN="center">
<P><BR><P>
<H2>Thanks <?php echo $sname ?></H2>
<P>
<B>Your card has been sent to <?php echo $rname ?> at <?php echo $rmail ?>.</B>
<P>
<P>
<a href="<?php echo $installpath ?>">Send Another Card</a>
</DIV>
Thank you before......
-Lucky