PHP Classes

Error

Recommend this page to a friend!

      Simple MySQL Class  >  All threads  >  Error  >  (Un) Subscribe thread alerts  
Subject:Error
Summary:Error in query, two objects of same class
Messages:2
Author:Petar Benke
Date:2008-12-30 12:38:21
Update:2008-12-30 12:45:52
 

  1. Error   Reply   Report abuse  
Picture of Petar Benke Petar Benke - 2008-12-30 12:38:21
I made two objects of this class and got the following error in second object:

Warning: mysql_error(): 3 is not a valid MySQL-Link resource in /home/brzimko/public_html/include/class.mysql.php on line 29
Error in query select datum, vreme, ime, komentar from komentari where odobren=TRUE and vest=1 order by id. In file in line 0. Date: 2008-12-30 13:33:12

It does not say what file and what line makes problem. SQL query is okay and returns rows.

  2. Re: Error   Reply   Report abuse  
Picture of Petar Benke Petar Benke - 2008-12-30 12:45:53 - In reply to message 1 from Petar Benke
Ups, I had $db->close() in wrong place of code :)

Apologies for that and yes this class works like a charm.