RE: [PHP] Need a little help with array

From: Date: Wed, 16 May 2001 02:58:28 +0000
Subject: RE: [PHP] Need a little help with array
Groups: php.general 
Request: Send a blank email to php-general+get-52979@lists.php.net to get a copy of this message
Try this instead: $sql = " SELECT CONCAT(fname, ' ', lname, '<', email, '>') AS str_email FROM customers "; and then the rest of your code.. Sincerely, Maxim Maletsky Founder, Chief Developer PHPBeginner.com (Where PHP Begins) maxim@phpbeginner.com www.phpbeginner.com -----Original Message----- From: Richard Kurth [mailto:rkurth@pacifier.com] Sent: Wednesday, May 16, 2001 10:49 AM To: php-general@lists.php.net Subject: [PHP] Need a little help with array I am trying to get the first name and Last name plus the email address out of the database in a format like this Richard Kurth<rkurth@pacifier.com>;Richard Kurth<rkurth@northwesthost.com> so I can put it in the BCC section of a mail all customer program What I have below works for getting the email out but I can't figure out how to get the rest out all together $sql = "SELECT email,fname,lname FROM customers"; $result = mysql_query($sql); $recipient = array(); while ($myrow = mysql_fetch_array($result)) $recipient[] = $myrow["email"]; $recipient_list = implode(",", $recipient); Best regards, Richard mailto:rkurth@pacifier.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#52979) next »