The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
In our site, we use 3.0.xx.
Some of our threads are quite large (about 50 pages or more). So I decided to imitate the drop-down menu shown in the latest releases of vB, where you are allowed to enter a number, hit the Go menu and the program takes you to the specified page in the thread. I am using a drop-down menu (vbmenu_register) to create the drop-down menu, in the pagenav template. The code for the menu is entered in the SHOWTHREAD or SHOWFORUM templates (that's where I need the drop-down menu) and it is just a form to get the page number where you want to go). The code works fine in the page navigation section on the top of the page, but does not work at the bottom one. From some tests I did, it looks as if you can't use vbmenu_register, to register a menu more than once. Any ideas how to solve this problem? Here is the code I am using: In template pagenav: After: Code:
<if condition="$show['last']"><td class="alt1"><a class="smallfont" href="$address&page=$totalpages$address2" title="$vbphrase[last_page] - <phrase 1="$lastnumbers[first]" 2="$lastnumbers[last]" 3="$total">$vbphrase[results_x_to_y_of_z]</phrase>">$vbphrase[last] <strong>»</strong></a></td></if> Code:
<if condition="$show['popups']"><td id="pagenav" class="vbmenu_control" title="$address$address2"><a name="PageNav"></a> <script type="text/javascript"> vbmenu_register("pagenav"); </script></td></if> And in template SHOWTHREAD, I entered this code as an additional drop-down menu. Code:
<!-- Page Navigation form menu --> <if condition="$show[popups]"> <div class="vbmenu_popup" id="pagenav_menu" style="display:none"> <form action="$address" method="post"> <table cellpadding="4" cellspacing="1" border="0"> <tr> <td class="thead" nowrap="nowrap">Go to Page...</td> </tr> <tr> <td class="vbmenu_option" title="nohilite"> <if condition="THIS_SCRIPT=='showthread'"><input type="hidden" name="perpage" value="$vboptions[maxposts]" /><else /><input type="hidden" name="perpage" value="$vboptions[maxthreads]" /></if> <input type="text" class="bginput" name="pagenumber" size="4" /> <input type="submit" class="button" value="$vbphrase[go]" /><br /> </td> </tr> </table> </form> </div> </if> |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|