Howdy folks, Im rather new to PHP and even newer to databases so go easy on me! Im trying to basically connect to a database, gather a set of information which could consist of multiple rows. Then place this set of data into an array, finally I would like to output each of the rows in this array as standard output(the order which it is output is not important)
Any insight would be appricated, for some reason I keep getting errors with this line:
while ($row = mysql_fetch_array($result, MYSQL_NUM))
The error messages say invalid argument
hmmm....
well thanks for looking!
<?php
mysql_connect($host,$user,$pass);
mysql_select_db("$db");
$query = "SELECT * FROM articles WHERE refnum = 3 OR name = broom OR fileloc = wheel OR idnum=5";
$result = mysql_query($query);
while ($row = mysql_fetch_array($result, MYSQL_NUM))
{
echo[$row];
}
?>