|
-
Jul 31st, 2003, 10:50 AM
#1
Thread Starter
Lively Member
email via php [RESOLVED]
hello,
I am using this script to send HTML email via PHP but all I get is a number 479$...
<?
//add From: header
$headers = "From:ybweb order form <> \n";
$headers .= "Reply-To:[email protected]\n";
//specify MIME version 1.0
$headers .= "MIME-Version: 1.0\n";
//unique boundary
$boundary = uniqid("HTMLEMAIL");
//tell e-mail client this e-mail contains//alternate versions
$headers .= "Content-Type: multipart/alternative"."; boundary = $boundary \n\n";
//message to people with clients who don't
//understand MIME
$headers .= "This is a MIME encoded message.\n\n";
//plain text version of message
$headers .= "--$boundary \n"."Content-Type: text/plain; charset=ISO-8859-1\n"."Content-Transfer-Encoding: base64\n\n";
$headers .= chunk_split(base64_encode("Plain Text Message Goes HERE"));
//HTML version of message
$headers .= "--$boundary\n"."Content-Type: text/html;\n"."Content-Transfer-Encoding: base64\n\n";
$HTML_SAVE =
"<HTML><body><table cellpadding=4 cellspacing=1><tr><th>Seplementals</th><th>Amount</th><th>Price</th><th>ddd</th><tr><td>Extra pages</td><td>".$numPages."</td><td>".$pagePrice." $</td><td>".$numPages*$pagePrice." $</td><tr><td>Extra Forms</td><td>".$numForms."</td><td>".$formPrice." $</td><td>".$numForms*$formPrice." $</td><tr><td>Extra Server Forms</td><td>".$numSForms."</td><td>".$sformPrice." $</td><td>".$numSForms*$sformPrice." $</td><tr><td>Basic Package</td><td>1</td><td>".$packPrice." $</td><td>".$packPrice." $</td><tr><td>Total</td><td></td><td></td><td>".$numPages*$pagePrice + $numForms*$formPrice + $numSForms*$sformPrice + $packPrice." $</td></table></body></HTML>";
$headers .= chunk_split(base64_encode($HTML_SAVE));
//send message
mail ("[email protected]", "test php mail", "", $headers);
?>
the long line you see is a table that I try to send.
iso I put it as a long long string and used some variables in it.
all this table should be send to me to my email but I recive only 1 number which is 479$ isnt that the way to send HTML tables?
Yair
Last edited by yair24; Sep 8th, 2003 at 01:15 AM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|