The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
pagination and drop down session
I have successfully setup pagination for my new modification, which gets the information from the database then limits the results to 10 items per page.
The only trouble is that I would now like to sort the items by different values, but I am not sure how sessions work in the respect do I need to add a column to the MySQL database or just setup a session variable? This is my code: PHP Code:
PHP Code:
file_fullsize I guess that i need to store the drop down orderby variable across the pagination? Thank you for any help Mick |
#2
|
||||
|
||||
You need to add your sort value to the pagination url parameters, then retrieve it (using get, not post in the input cleaner).
Don't forget to set your dropdown to the chosen value. |
#3
|
|||
|
|||
Quote:
I used the guide on here to setup the pagination, This code is used in the pagination, to be honest, I did not take much notice of it just that it worked... But is this where I need to append the GET of the orderby value? PHP Code:
Mick --------------- Added [DATE]1434095288[/DATE] at [TIME]1434095288[/TIME] --------------- Cellerus you are a Legend, it was so easy when you think about it!!! For anyone looking for the same issue I did as said above changed everything to GET (not POST). then just added in the orderby into the pagination construct PHP Code:
|
Благодарность от: | ||
MarkFL |
#4
|
||||
|
||||
Glad you got it sorted (pun fully intended)
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|