Problems trying to load libraries on my controllers

#1
[eluser]Unknown[/eluser]
Hi all, i have a little problem trying to charge some libraries on my controller, one of that is using pagination library, i have the basic code :
Code:
$this->load->library('pagination');

$config['base_url'] = 'http://example.com/index.php/test/page/';
$config['total_rows'] = '200';
$config['per_page'] = '20';

$this->pagination->initialize($config);

echo $this->pagination->create_links();

But this code show me an error when i try to use initialize() : Call to a member function on a non-object

The same problem with database library, but curiously, this don't occur with url helper or with my own libraries.

BUT if i put this libraries (pagination, databese) in autoload.php ALL RUNS FINE!.
Some idea about that? TNX!!


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.