problem with WHILE loop

From: Date: Mon, 01 Oct 2001 01:32:20 +0000
Subject: problem with WHILE loop
Groups: php.db 
Request: Send a blank email to php-db+get-12855@lists.php.net to get a copy of this message
I have the following code on a page: <?php $list = mysql_query("select id,title from table1"); $list_row = mysql_fetch_array($list); $title = $list_row["title"]; while($list_row) { echo("$title <br>\n"); } ?> For some reason, when I load the page, instead of a list of the titles from table1, I get the title from the first row of table1 repeated over and over. Obviously I'm doing something wrong, and it's probably something really dumb, right in front of my face... but I can't find it! help? Thanks, Eric Schwinder eric.AT.bergencomputing.DOT.com AT = @ DOT = (well... you know)

« previous php.db (#12855) next »