The Arcive of vBulletin Modifications Site. |
|
|
[How To] Paginate Admin CP Results
Had just finished developing a hack, and realized over time that the pages in the admin cp would become quite long if they weren't paginated, so I ventured into the modcp/banning.php file to help me out... This article is for hack authors, and presumes you are familiar with vBulletin and PHP in general. First block of code... PHP Code:
Then the output of the pagination... PHP Code:
Then there's your query: PHP Code:
If you've done it correctly you should have page navigation on your admin cp page. Here's the code in full from one of my pages, if you don't understand anything above: PHP Code:
)Also, thanks to Revan for his [How-To] Paginate your results for user pages. |
|
#2
|
||||
|
||||
|
Awsome TX....
5x stars EDIT : Im haveing problems with linking to pages.. The problem is, linking from pagenavs and the one that lists my query is DO Find and when i change the pagenav to fit the links to the other pages fail Code:
$pagenav .= " <a href=\"sh2.php?$session[sessionurl]do=Find&page=$thispage\" class=\"normal\">$thispage</a> "; and find is the one printing results, and works fine, only shows the ammount i set it for, howewer when clicking additional pages, it goes blank just as if it cant located the requested destination.. any suggestions ? Im confused where the link goes, i can see it goes to do=find but the rest page=X heh nope. |
|
#3
|
||||
|
||||
|
Sorry for the late reply... don't come on here often.
Would you mind PM'ing me your file, and I'll take a look at it? |
![]() |
|
|