Problem: mysql_fetch_array() expects parameter 1 to be resou

Codes here !

Moderators: macek, egami, gesf

Post Reply
johnj
php-forum Super User
php-forum Super User
Posts: 1805
Joined: Thu Mar 10, 2011 5:07 pm

Re: Problem: mysql_fetch_array() expects parameter 1 to be r

Post by johnj » Tue Apr 23, 2013 6:00 am

Are you sure that your query is returning rows and not returning 'false' ??/

http://phillipnb.wordpress.com/2010/12/ ... -resource/

seandisanti
php-forum Fan User
php-forum Fan User
Posts: 973
Joined: Mon Oct 01, 2012 12:32 pm

Re: Problem: mysql_fetch_array() expects parameter 1 to be r

Post by seandisanti » Thu Apr 25, 2013 8:10 am

You're probably going to have intermittent success with it, because you've not done the proper return validation. If there's an error executing your query, the return is going to be false, instead of a resource. so then when you go to fetch_array() you're going to run into the same error again.

Post Reply

Who is online

Users browsing this forum: Baidu [Spider] and 1 guest