Welcome Guest, Not a member yet? Register   Sign In
Where DB function is not recognized by the system. Why?
#1

[eluser]Rubiz'[/eluser]
Hello all

I am with a problem, make no idea about solution... Well, its not the first time it happens; the $this->db->where function is not recognized by the system...

I got this error:
Code:
Fatal error: Call to a member function where() on a non-object in /nfs/c01/h04/mnt/45239/domains/webresolv.com.br/html/alkindar/system/application/models/pages_model.php on line 30

The line code...

Code:
$this->db->where('is_class', 1);

Any idea about solution?
#2

[eluser]TheFuzzy0ne[/eluser]
Have you loaded the database? If so, where?

EDIT: If you've loaded the database and you are still getting the error, ensure that your controller class extends Controller.

Code:
class Some_controller extends Controller {
// ...
#3

[eluser]Tom Schlick[/eluser]
is active record enabled on ur db connection?
#4

[eluser]Rubiz'[/eluser]
Well guys, thanx for help, I have made some tests than I put back the library 'database' in autoload file and everything is ok... I can't really understand what have happened...

Thanx
#5

[eluser]TheFuzzy0ne[/eluser]
Please paste your controller.




Theme © iAndrew 2016 - Forum software by © MyBB