Welcome Guest, Not a member yet? Register   Sign In
Load pagination config from file
#1

[eluser]Felipe Diesel[/eluser]
Hi,

I have upgraded CI to 1.6.2 and the config under config/pagination.php is not being loaded when I show pagination.

This is my config file:
Code:
<?php

$config['per_page'] = 50;
$config['num_links'] = 5;
$config['first_link'] = '<<';
$config['last_link'] = '>>';
$config['full_tag_open'] = '<div class="pagination">';
$config['full_tag_close'] = '</div>';

'per_page' is loading, but the rest no, still CI default.
#2

[eluser]Felipe Diesel[/eluser]
I already find a way to solve it.

I was loading config/pagination.php in autoload, because I was using

Code:
$query = $this->db->get('resumes', $this->config->item('per_page'), $this->uri->segment(4,0));

And this autoload was breaking the load inside pagination class.

I don't know if it's a bug, but I do a workaround.




Theme © iAndrew 2016 - Forum software by © MyBB