Jump to content

Archived

This topic is now archived and is closed to further replies.

gerrydewar

Message: Resource id#3

Recommended Posts

I'm making a simple query to my database and receiving a code:Resource id#3 as my output. Does anyone know what this means?

I've tried to post the code i'm using but i keep getting the following error when my code is included in this thread:

Not Acceptable
An appropriate representation of the requested resource /forums/index.php could not be found on this server.





Share this post


Link to post
Share on other sites
You are probably doing (can't post any code :-( )

$rs = mysql query ("string")

echo $rs;

You need to fetch the rows after the query.


Ken

Share this post


Link to post
Share on other sites
I was doing what you said i was so i added the following:

while($row=mysql_fetch_array($result,MYSQL_ASSOC)){
echo $row;
}


Now i get the word 'Array' as my output.


Share this post


Link to post
Share on other sites
Fixed it. Just took out the MYSQL_ASSOC from the while loop and it worked. Thanks to Ken and Barand for posting that nice tutorial on the other thread.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.