Welcome Guest, Not a member yet? Register   Sign In
[SOLVED] Pagination - no custom params (next_link..) appears
#1

[eluser]predat0r[/eluser]
Hi,
I have pagination applied in my code, it works perfectly, except the customizations. I set next_link, first_link .. but it shows the default buttons only. Any idea, why?

Code:
$config['base_url'] = 'http://localhost/somepage/main/index/';
        $config['total_rows'] = $this->db->get('kerdesek')->num_rows();
        $config['per_page'] = 3;
        $config['num_links'] = 5;
        $config['first_link'] = 'First';
        $config['last_link'] = 'Last';
        $config['next_link'] = '>';
        $config['prev_link'] = '<';
        $config['cur_tag_open'] = '<b>';
        $config['cur_tag_close'] = '</b>';
        
        $this->pagination->initialize($config);
        
        $data['records'] = $this->kerdes_model->kerdesek('desc', $config['per_page'], $this->uri->segment(3));
        $this->load->view('kerdes_view', $data);

Model:
Code:
function kerdesek($sorrend, $limit, $uri) {
            $this->db->order_by('datum', $sorrend);
            $this->db->limit($limit, $uri);
            $q = $this->db->get('kerdesek');
            return $q->result();            
        }

thanks
#2

[eluser]Akinzekeel[/eluser]
Did you try something different than these brackets?

Are you using HTML entities (like in the CI user guide) or just the plain brackets?
#3

[eluser]predat0r[/eluser]
Thanks, I changed the brackets to text, it works. But, can you beleive it? After it rendered good on view, I tried to change the texts to brackets and entities, and it works with them. Strange.......




Theme © iAndrew 2016 - Forum software by © MyBB