Hey I'm have problems with mysql_fetch_array(). I've looked around and couldn't find anyone with the same problem, though I've probably looked in the wrong places.
This is my code:
<?php
include "var.php";
$connect = mysql_connect($dbcon[host],$dbcon[user],$dbcon[pass])
or die(mysql_errno().": ".mysql_error());
mysql_select_db($dbcon[name]);
$query = "SELECT type, type_id, price
FROM $dbtable[trailer]
ORDER BY type_id";
$result = mysql_query($query)
or die(mysql_errno().": ".mysql_error());
$content = "";
while($row=mysql_fetch_array($results))
{
extract($row);
$content .= "$row[type]: $row[price]";
}
include "temp.php";
?>
when i run the code i get this error:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in e:\websites\hireco2\common\browse.php on line 19
Thanks for your help.