| Welcome to WebmasterWorld Guest from 188.8.131.52 |
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
|Become a Pro Member|
formatting an array when select * is used
| 7:58 pm on Jun 30, 2009 (gmt 0)|
This is probably an easy answer, but when I use the code below my output is all on one line like
There are only 2 fields on this table, ID and ITEM.
I'd like it to print in this format:
$query = mysql_query("SELECT * FROM menu")
or die (mysql_error());
while ($data = mysql_fetch_array($query, MYSQL_ASSOC))
| 8:12 pm on Jun 30, 2009 (gmt 0)|
echo $data['ITEM']."<br />\r\n";
| 8:40 pm on Jun 30, 2009 (gmt 0)|
All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved