0

I thought of implementing multiple pagination concept in a single page.I applied pagination concept but instead of changing only one set of records it gets reflected to another set of records.Can anyone solve this.

2
Contributors
3
Replies
4
Views
7 Years
Discussion Span
Last Post by wilch
0

Well, we can't solve what we can't see. Give us the logic of the code or rather the code itself then we might determine whether we can/not solve it :)

0

The logic is to display categories and subcategories under that categories.I want pagination to those subcategories which looks like

cat1
subcat1
subcat2

// pagination code//

cat2
subcat1
subcat2

// pagination code//

0

Well, i have developed something similar tot that before.
What you first need is the pagination code. Then add to each url of the pagination links extra variables that maintain the current state of every category & subcategory being displayed at that moment.

e.g.
Category A has the following
{
link1
- has state 20
- url (category=a&link=1&B_x=3&B_y=14&B_z=24)

link2
- has state 10
- url(category=a&link=2&B_x=3&B_y=14&B_z=24)
}

Category B has the following {
link1
- has state 3
- url (category=b&link=1&A_x=10&A_y=20)

link2
- has state 14
- url(category=b&link=2&A_x=10&A_y=20)

link3
- has state 24
- url(category=b&link=3&A_x=10&A_y=20)
}

In the example what i am trying to say is, the links in each category maintain the current state of what's currently displayed in the other category, this way when the page reloads, you use the the variables you passed in the url to maintain the other categories/subcategories.

So by saying e.g.
in category b link 3
url(category=b&link=3&A_x=10&A_y=20) means pass the variables category=b and link=3, to the pagination.php file for processing, and then when you reload the results page maintain the results from Category A as:
link 1 (aka A_x) has state 10
link 2 (aka A_y) has state 20.

This way we have maintained what was previously displayed in Category A, but only altered what's displayed in B.

If you need more elaboration i can provide.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.