compsol
02-12-2012, 11:18 PM
Using many PHP mauals and tutorials, I have not found out how to do the following:
Below is the PHP code (which actually works, by the way, except in one area). The problem I am having is in the output (as you can see below the code). In the output, please notice that the HTML tags that are used in attempt to bold some output, using <b> & </b> ... and also to use the font color tag, using <font color=brown> and </font> ... these do not work. The remainder of the program works as intended ... except that you will notice (below the PHP code ... in the email received by the reciprients), the HTML tags are not working.
Does anyone know what I need to do. Thanks for any help.
<?php
$name = "Donald Duck";
$subject = "March 2012 Meeting Update";
$message = "Hello! ".$name." has just posted a new message with Subject: \"".$subject."\"\n"."on our <b>NameofBusiness Message Board!</b>\n\n<font
color=brown>Please visit the below URL to view the message.</font>\n\n".
"www.noname.com/NameofBusiness/Time4meeting/$newfile.\n\nAlso, you may visit the <b>NameofBusiness Web Site</b> at: www.NameofBusiness.com/.\nNOTICE:
All you need to do is CLICK on the LINKS (above) which are in blue.
End of message
";
$ae[0]="sonofwascallywabbit@yahoo.com";
$ae[1]="agal@gmail.com";
$ae[2]="bguy@gmail.com";
$ae[3]="bgal@gmail.com";
$ae[4]="cgal@gmail.com";
$ae[5]="cgal@gmail.com";
$ae[6]="dguy@gmail.com";
$ae[7]="dgal@gmail.com";
$ae[8]="eguy@gmail.com";
$ae[9]="egal@gmail.com";
$ae[10]="fguy@gmail.com";
$ae[11]="fgal@gmail.com";
$ae[12]="gguy@gmail.com";
$ae[13]="ggal@gmail.com";
$ae[14]="hguy@gmail.com";
$ae[15]="hgal@gmail.com";
$ae[16]="iguy@gmail.com";
$ae[17]="jgal@gmail.com";
$ae[18]="jguy@gmail.com";
$ae[19]="kgal@gmail.com";
$ae[20]="kguy@gmail.com";
$ae[21]="lgal@gmail.com";
$ae[22]="lguy@gmail.com";
$i = 0;
while ($i <= 22)
{
mail($ae[$i],'New NameofBusiness Message Board post',$message);
$i = $i + 1;
}
/* */
?>
************************************************
An actual email received by each recipient follows:
************************************************
--- On Sun, 2/12/12, ipw.droarkco@boscgi0204.eigbox.net <ipw.droarkco@boscgi0204.eigbox.net> wrote:
From: ipw.droarkco@boscgi0204.eigbox.net <ipw.droarkco@boscgi0204.eigbox.net>
Subject: New NameofBusiness Message Board post
To: sonofwascallywabbit@yahoo.com
Date: Sunday, February 12, 2012, 4:28 PM
Hello! Donald Duck has just posted a new message with Subject: "March 2012 Meeting Update"
on our <b>NameofBusiness Message Board!</b>
<font color=brown>Please visit the below URL to view the message.</font>
www.noname.com/NameofBusiness/Time4meeting/.
Also, you may visit the <b>NameofBusiness Web Site</b> at: www.NameofBusiness.com/.
NOTICE: All you need to do is CLICK on the LINKS (above) which are in blue.
End of message
Below is the PHP code (which actually works, by the way, except in one area). The problem I am having is in the output (as you can see below the code). In the output, please notice that the HTML tags that are used in attempt to bold some output, using <b> & </b> ... and also to use the font color tag, using <font color=brown> and </font> ... these do not work. The remainder of the program works as intended ... except that you will notice (below the PHP code ... in the email received by the reciprients), the HTML tags are not working.
Does anyone know what I need to do. Thanks for any help.
<?php
$name = "Donald Duck";
$subject = "March 2012 Meeting Update";
$message = "Hello! ".$name." has just posted a new message with Subject: \"".$subject."\"\n"."on our <b>NameofBusiness Message Board!</b>\n\n<font
color=brown>Please visit the below URL to view the message.</font>\n\n".
"www.noname.com/NameofBusiness/Time4meeting/$newfile.\n\nAlso, you may visit the <b>NameofBusiness Web Site</b> at: www.NameofBusiness.com/.\nNOTICE:
All you need to do is CLICK on the LINKS (above) which are in blue.
End of message
";
$ae[0]="sonofwascallywabbit@yahoo.com";
$ae[1]="agal@gmail.com";
$ae[2]="bguy@gmail.com";
$ae[3]="bgal@gmail.com";
$ae[4]="cgal@gmail.com";
$ae[5]="cgal@gmail.com";
$ae[6]="dguy@gmail.com";
$ae[7]="dgal@gmail.com";
$ae[8]="eguy@gmail.com";
$ae[9]="egal@gmail.com";
$ae[10]="fguy@gmail.com";
$ae[11]="fgal@gmail.com";
$ae[12]="gguy@gmail.com";
$ae[13]="ggal@gmail.com";
$ae[14]="hguy@gmail.com";
$ae[15]="hgal@gmail.com";
$ae[16]="iguy@gmail.com";
$ae[17]="jgal@gmail.com";
$ae[18]="jguy@gmail.com";
$ae[19]="kgal@gmail.com";
$ae[20]="kguy@gmail.com";
$ae[21]="lgal@gmail.com";
$ae[22]="lguy@gmail.com";
$i = 0;
while ($i <= 22)
{
mail($ae[$i],'New NameofBusiness Message Board post',$message);
$i = $i + 1;
}
/* */
?>
************************************************
An actual email received by each recipient follows:
************************************************
--- On Sun, 2/12/12, ipw.droarkco@boscgi0204.eigbox.net <ipw.droarkco@boscgi0204.eigbox.net> wrote:
From: ipw.droarkco@boscgi0204.eigbox.net <ipw.droarkco@boscgi0204.eigbox.net>
Subject: New NameofBusiness Message Board post
To: sonofwascallywabbit@yahoo.com
Date: Sunday, February 12, 2012, 4:28 PM
Hello! Donald Duck has just posted a new message with Subject: "March 2012 Meeting Update"
on our <b>NameofBusiness Message Board!</b>
<font color=brown>Please visit the below URL to view the message.</font>
www.noname.com/NameofBusiness/Time4meeting/.
Also, you may visit the <b>NameofBusiness Web Site</b> at: www.NameofBusiness.com/.
NOTICE: All you need to do is CLICK on the LINKS (above) which are in blue.
End of message