Email Selected Data

From: Date: Sun, 04 Feb 2001 20:31:49 +0000
Subject: Email Selected Data
Groups: php.general 
Request: Send a blank email to php-general+get-38140@lists.php.net to get a copy of this message
Hi, I am selecting data using the below and trying to insert it into a mail, it does everything except send the data selected, anyone have an idea? $SQLStatement = "SELECT * FROM Orders Where Status='N' Order by OrderID"; $SQLConn = mysql_connect($host, $user, $pass); $db = mysql_select_db($dbase, $SQLConn); $SQLResult = mysql_query($SQLStatement); $num_rows=mysql_num_rows($SQLResult); for ($i=0; $i<$num_rows; $i++) { mysql_data_seek($SQLResult, $i); $array=mysql_fetch_array($SQLResult); $content=printf("First Name: %s\nLast Name: %s\n",$array['FirstName'], $array['LastName']); } mail($MAIL, "Order", $content , "From:ade@address.com"); I know it is working to a degree because it prints out the data on the resulting page and sends a blank email, it just doesn`t put it in the email. TIA Ade

« previous php.general (#38140) next »