is there a way to create a mail (with the mail() function) that contains php in the message.
Like:
<?php $to = "[EMAIL PROTECTED]"; $subject = "a subject"; $message = ????
I WANT TO PUT SOME PHP IN HERE TO CREATE A TABLE IN THE MESSAGE:
$columnbooks = mysql_list_fields($dbname,tmp,$mysql_link);
$sqlbooks = "select isbn,books.title, writer, publisher from tmp,books where tmp.user=books.user";
$resultbooks = mysql_db_query($dbname,$sqlbooks);
?>
<table cellpadding="2" cellspacing="2" border="1" style="text-align: left; width: 100%;">
<?php
while ($valuebooks = mysql_fetch_array($resultbooks))
{ print "<tr bgcolor=#ccf504>";
for($i=0; $i< 4; $i++ )
{
$gebruikerbooks=$valuebooks[$i];
print "<td> $gebruikerbooks </td>";
}
print "</tr>";
}
mysql_free_result($resultbooks);
THIS SHOULD BE THE END OF THE MESSAGE
HERE I WILL DO THE MAILING
mail($to,$subject,$message); ?>
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php