The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
php code in template for pagination
I have this chunck of code with for statements. I need to bring that in template because I want to display those those link near mod. Right now it is displaying at top of page like 1 2 3 4,.Links are working fine with currentpage no link. Code is working but it is displying on top since it is in php page all the records are in template.
I want to display the links near mod. the only way I can do is I have to bring this below code with for statements and links to display the current page and all other pagelinks. Please can anyone can guide me, how can we display near section with if conditions. $numofpages = $totalrows / $limit; for($i = 1; $i <= $numofpages; $i++){ if($i == $page){ echo($i." "); $currentpage= $i." "; }else{ echo("<a href=\"$PHP_SELF?page=$i\">$i</a> "); } } $totallimit=$totalrows % $limit; if(($totalrows % $limit) != 0){ if($i == $page){ echo($i." "); //$currentpage = $i; }else{ echo("<a href=\"$PHP_SELF?page=$i\">$i</a> "); } } I'll provide more details if needed I really appreciate, if I get any help on this. Thanks |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|