Hallo Zusammen habe ein Problem habe auf Homepage IS wenn man sich registriert und drauf geht kommt das:
Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /usr/local/www/apache24/data/pages/itemshop.php on line 17
Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /usr/local/www/apache24/data/pages/itemshop.php on line 27
itemshop.php Quellcode:
<?php
echo "<div class=\"contentBoxTop\"></div>
<div class=\"contentBox\"><div class=\"innerBox\">
<table border=\"0\">
<tr><th width=\"200\">Bild</th><th width=\"200\">Name</th><th width=\"200\">Preis</th><th width=\"200\">Kaufen</th></tr>";
$db = "account";
mysql_connect($dbhost, $dbuser, $dbpw) OR
die("ERROR: Connection failed. ".mysql_error());
mysql_select_db($db) OR
die("ERROR: DB allready open. ".mysql_error());
$sql = mysql_query("SELECT * FROM itemshop ORDER BY id DESC LIMIT 0,3");
while($fetch = mysql_fetch_object($sql)) {
echo "<tr><td width=\"200\"><img src=\"../../images/items/$fetch->value.gif\"></td><td width=\"200\">$fetch->itemname</td><td width=\"200\">$fetch->coins</td><td width=\"200\"><a href=\"shopbuy.php?id=$fetch->value\">Kaufen!</a></td></tr>";
}
echo "</table></center><br></div></div><div class=\"contentBoxBottom\"></div><br>";
?>
Homepage link 185.5.174.125
THx im vorraus
LG gobi1