Fatal error: Call to a member function query() on a non-object |
[eluser]Creox[/eluser]
[quote author="John_Betong_002" date="1308254970"]Have you tried using another table name? Also try http://localhost/phpmyadmin/index.php and check your database and tables. [/quote] John, The tbales are in the database that i connect to succesffully. When I exectue the following code Code: $query = $this->db->query('SELECT * FROM users WHERE UserID = '.$userID.' LIMIT 1'); I expect to get a result back. However I get the following Quote:A PHP Error was encountered i have autoloaded the database in config/autoload.php Code: $autoload['libraries'] = array('database'); What else could it be? This is driving me insane. I have just downloaded CI v2.01 at the error still occurs. Please help. Thanks Ciaran |
Welcome Guest, Not a member yet? Register Sign In |