tariqrf 0 Report post Posted April 20, 2005 i put up a PHP and MYSQL site recently, which was hosted on tripod(loosers), where it used to work fine,i put i up here again, it says: Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/tariq/public_html/fsgr/script/orders.php on line 47 what does this mean, is the PHP or MYSQL version up to date?? or is there somthing wrong with my coding,Please helpTariq Share this post Link to post Share on other sites
beeseven 0 Report post Posted April 20, 2005 Something's wrong with your code. That happens to me a lot, too. I can usually fix it by just messing around with how I do the query. It's also sometimes a problem with variables getting lost. Try making it echo the query ($query = etc.; mysql_query($query); echo $query;) to see if it's doing it right. Share this post Link to post Share on other sites
tariqrf 0 Report post Posted April 21, 2005 Something's wrong with your code. That happens to me a lot, too. I can usually fix it by just messing around with how I do the query. It's also sometimes a problem with variables getting lost. Try making it echo the query ($query = etc.; mysql_query($query); echo $query;) to see if it's doing it right. 132116[/snapback] <?$res = mysql_query("select * from orders");while($row = mysql_fetch_array($res)){ print "<tr><td valign=top>" . $row['orderid'] . "</td><td>" . $row['name'] . "</td><td>" . $row['tel'] . "</td><td>" . $row['address'] . "</td><td>" . $row['cart'] . "</td><td>" . $row['comments'] . "</td><td><a href=\"delete.php?id=" . $row['id'] . "\">delete</a></td></tr>";}?> this is the full code,,, whats wrong??? Share this post Link to post Share on other sites
Argoth 0 Report post Posted April 21, 2005 More than likely you didn't created the table orders, or perhaps there I no data there.So make sure the table exists, has some columns is it, and has some data (but this really shouldn't matter) Share this post Link to post Share on other sites
serverph 0 Report post Posted April 21, 2005 when you transferred your site from tripod, you should look into it that you did not just transfer the PHP files only, but also the MYSQL database accessed by your pages as well. if you desire to start from scratch with your database, just create the appropriate DB from your cpanel. :lol:if it has been working with tripod before, there's no reason it wouldn't run with Xisto too. Share this post Link to post Share on other sites
tariqrf 0 Report post Posted April 22, 2005 COOL!! IT WORKS!! i really donno what i did, but it finally works!!omg,Thanx guyz,T. Share this post Link to post Share on other sites