Jump to content

Problems with understanding errors...


tuna1

Recommended Posts

Hi,

 

I'v just installed some auction software and have discovered a pretty major flaw. 2 days later and i'm still waiting to hear from customer service so i'm going to try and solve it myself. Here is the error message

 

Warning: implode() [function.implode]: Bad arguments. in /home/wwwmidb/public_html/catlistings.php on line 54

 

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/wwwmidb/public_html/catlistings.php on line 107

 

I have also attached the PHP file. Now i'm not sure if the problem is something to do with the database, and not the actual PHP file but could someone try and explain the syntax of the errors? Look forward to hearing any replies,

 

James

 

[attachment deleted by admin]

Link to comment
https://forums.phpfreaks.com/topic/46411-problems-with-understanding-errors/
Share on other sites

The implode error may be caused because you are not passing it an array. implode only accepts an array nothing else. Also make sure you are not feeding it a multidimensional array. I don't think it can process multidimensional arrays.

 

the other error is usually caused because you have an error in your SQL query. To see if your sql query has an error add

or die(mysql_error());

to the end of mysql_query function that is near line 107 in catlistings.php

It seems there is an error in the mysql query. After adding that code i recieve

 

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/wwwmidb/public_html/catlistings.php on line 107

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') OR a.addlcategory IN ()) AND a.listin!='auction' AND a.active='1' AND a.clo' at line 2

 

Do you think there is an easy solution to these problems? Many thanks

Archived

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

×
×
  • Create New...

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.