Welcome Guest, Not a member yet? Register   Sign In
Pagination Links
#1

[eluser]cybersven[/eluser]
Hi,

I'm using Pagination Class everything is working correctly.

My actual URLs are like :
Code:
http://mysite.com/index.php/home/index/0
http://mysite.com/index.php/home/index/4
http://mysite.com/index.php/home/index/8
...
So 4 results per page.

Now I've added a category in the url like :
Code:
http://mysite.com/index.php/home/index/0/A
and it works

but I want that the pagination class give me next links like :
Code:
http://mysite.com/index.php/home/index/4/A
http://mysite.com/index.php/home/index/8/A
http://mysite.com/index.php/home/index/12/A
...
and actually next page give me this link :
http://mysite.com/index.php/home/index/4

How can I add this segment in the links ?

Thx in advance
#2

[eluser]cybersven[/eluser]
I've found the solution in the Library :-D

Code:
$config['suffix']

So here is my solution :

Code:
$cat = ($this->uri->segment(4)) ? $this->uri->segment(4) : 0;
$config['suffix'] = '/'.$cat;




Theme © iAndrew 2016 - Forum software by © MyBB