When you create $selections
Make sure you add a '\n' to the end of each line...

EG:
$selection .= "$myrow[result1]\n";





"BigMark" <[EMAIL PROTECTED]> 
03/06/2004 08:28

To
[EMAIL PROTECTED]
cc

Subject
[PHP] email formatting






Is it possible to have this code changed easily to make the output run
horizontally instead of vertically.  example of current output to email
below code


////////////////////////////////////////////////////////////////////////////
//////////////////////////////////
//email selections to all users
$sql = "SELECT email_address FROM Users";
$result = mysql_query($sql);
while ($myrow = mysql_fetch_array($result)) {

$email = $myrow['email_address'];
$subject = "Mark's Footy Tipping Competition";
$message =
"Hi,
Round $Round is now closed.  Selections were:
$selections
Thanks!
Mark
This is an automated response, please do not reply!";
mail($email, $subject, $message, "From: Mark<$fromemailaddress>\nX-Mailer:
PHP/" . phpversion());

}
////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////

outputs like this

Hi,

Round 10 is now closed.  Selections were:


Glen Gosnay - Game 1 Essendon
Glen Gosnay - Game 2 Hawthorn
Glen Gosnay - Game 3 West Coast
Glen Gosnay - Game 4 Kangaroos
Glen Gosnay - Game 5 Sydney
Glen Gosnay - Game 6 Geelong
Glen Gosnay - Game 7 St Kilda
Glen Gosnay - Game 8 Brisbane
Wayne Gosnay - Game 1 Essendon
Wayne Gosnay - Game 2 Hawthorn
Wayne Gosnay - Game 3 West Coast
Wayne Gosnay - Game 4 Collingwood
Wayne Gosnay - Game 5 Sydney
Wayne Gosnay - Game 6 Port Adelaide
Wayne Gosnay - Game 7 St Kilda
Wayne Gosnay - Game 8 Brisbane
Sean Dsouza - Game 1 Essendon
Sean Dsouza - Game 2 Adelaide
Sean Dsouza - Game 3 West Coast
Sean Dsouza - Game 4 Collingwood
Sean Dsouza - Game 5 Sydney
Sean Dsouza - Game 6 Port Adelaide
Sean Dsouza - Game 7 St Kilda
Sean Dsouza - Game 8 Brisbane

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php





*********************************************************************
The information contained in this e-mail message is intended only for 
the personal and confidential use of the recipient(s) named above.  
If the reader of this message is not the intended recipient or an agent
responsible for delivering it to the intended recipient, you are hereby 
notified that you have received this document in error and that any
review, dissemination, distribution, or copying of this message is 
strictly prohibited. If you have received this communication in error, 
please notify us immediately by e-mail, and delete the original message.
***********************************************************************

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to