RE: [PHP-WIN] Need help with Echo
| From: | Rich Gray | Date: | Thu, 10 Oct 2002 13:56:25 +0000 |
| Subject: | RE: [PHP-WIN] Need help with Echo | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-16320@lists.php.net to get a copy of this message | ||
Bonjour Keith
Use mysql_fetch_array($result) not mysql_fetch_row($result) - this will
return an associative as well as a standard array.
Ciao
Rich
-----Original Message-----
From: Keith Calvert [mailto:nospam.k.calvert@aardvark.fr]
Sent: 07 July 2002 07:56
To: php-windows@lists.php.net
Subject: [PHP-WIN] Need help with Echo
Hi I've just started with Php and MySql
I have installed the PhpTriad all in one package on my windows XP and all
seems to be going
well.
I have the following problem, here is the code
$result = mysql_query("select * from proprietaires") or die(
mysql_error() );
while ($row = mysql_fetch_row($result))
{
echo "Id:";
echo $row["Id"];
echo "<br>\n";
echo $row[2];
echo "<br>\n";
}
The Echo $row["ID"] does not work
The Echo $row[2] does
This works on some of my other forms. any ideas or hints woul most certainly
be welcome
Thanks in advance
Keith
France
--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php