The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Navbar Drop down menu
Easy request and I'm positive there is a thread on it but I couldn't find it. Could someone code a drop down menu for the navbar? It should be similar to Quick Links with the categories and such.
I fiddled around for about 30 mins trying to copy code to make my own but it always broke the navbar. Or could someone point me in the direction of the other thread on this? I belive the person who created it named the dropdown menu "Interactive" ? |
#2
|
||||
|
||||
Bump? Anyone?
Just a simple drop down menu with categories :speechless: |
#3
|
|||
|
|||
In template navbar,
FIND: Code:
<if condition="$bbuserinfo['userid']"> <td id="usercptools" class="vbmenu_control"><a href="$show[nojs_link]#usercptools">$vbphrase[quick_links]</a> <script type="text/javascript"> vbmenu_register("usercptools"); </script></td> </if> Code:
<if condition="$bbuserinfo['userid']"> <td id="MYUNIQUEID" class="vbmenu_control"><a href="$show[nojs_link]#MYUNIQUEID">$vbphrase[MYPHRASE]</a> <script type="text/javascript"> vbmenu_register("MYUNIQUEID"); </script></td> </if> Code:
<if condition="$show['member']"> <!-- user cp tools menu --> <div class="vbmenu_popup" id="usercptools_menu" style="display:none"> <table cellpadding="4" cellspacing="1" border="0"> <tr><td class="thead">$vbphrase[quick_links]</td></tr> <if condition="$vboptions['enablesearches']"><tr><td class="vbmenu_option"><a href="search.php?$session[sessionurl]do=getdaily">$vbphrase[todays_posts]</a></td></tr></if> <tr><td class="vbmenu_option"><a href="forumdisplay.php?$session[sessionurl]do=markread">$vbphrase[mark_forums_read]</a></td></tr> <tr><td class="vbmenu_option"><a href="#" onclick="window.open('misc.php?$session[sessionurl]do=buddylist&focus=1','buddylist','statusbar=no,menubar=no,toolbar=no,scrollbars=yes,resizable=yes,width=250,height=300'); return false;">$vbphrase[open_buddy_list]</a></td></tr> <tr><td class="thead"><a href="usercp.php$session[sessionurl_q]">$vbphrase[user_control_panel]</a></td></tr> <if condition="$show['siglink']"><tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=editsignature">$vbphrase[edit_signature]</a></td></tr></if> <!--<if condition="$show['avatarlink']"><tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=editavatar">$vbphrase[edit_avatar]</a></td></tr></if>--> <tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=editprofile">$vbphrase[edit_profile]</a></td></tr> <tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=editoptions">$vbphrase[edit_options]</a></td></tr> <tr><td class="thead">$vbphrase[miscellaneous]</td></tr> <if condition="$show['pmstats']"><tr><td class="vbmenu_option"><a href="private.php$session[sessionurl_q]">$vbphrase[private_messages]</a></td></tr></if> <tr><td class="vbmenu_option"><a href="subscription.php$session[sessionurl_q]">$vbphrase[subscribed_threads]</a></td></tr> <tr><td class="vbmenu_option"><a href="member.php?$session[sessionurl]u=$bbuserinfo[userid]">$vbphrase[my_profile]</a></td></tr> <if condition="$show['wollink']"><tr><td class="vbmenu_option"><a href="online.php$session[sessionurl_q]">$vbphrase[whos_online]</a></td></tr></if> </table> </div> <!-- / user cp tools menu --> </if> Code:
<!-- MY CUSTOM MENU --> <div class="vbmenu_popup" id="MYUNIQUEID_menu" style="display:none"> <table cellpadding="4" cellspacing="1" border="0"> <tr><td class="thead">$vbphrase[PHRASE_CUSTOMMENU_TITLE1]</td></tr> <tr><td class="vbmenu_option"><a href="MYCUSTOMLINK.php?$session[sessionurl]">$vbphrase[MYCUSTOMLINK_TITLE]</a></td></tr> </table> </div> <!-- / MY CUSTOM MENU --> </if> MYUNIQUEID - all instances - with the same custom value EVERYTHING ELSE IN CAPS - with your custom content And of course, create the phrases you need. Done! I might add this to my custom vB-powered pages manual later on... |
#4
|
||||
|
||||
Cool, that worked
What would I have to do to insert this right after the UserCP link? |
#5
|
|||
|
|||
Then insert the first piece of code after the HTML for usercp
|
#6
|
|||
|
|||
If I may ask another question related to this, I'd like to ask:
I wanted to add the drop down to a custom field on the postbit_legacy template. This is the code I have on postbit_legacy: Code:
<table id="post$post[postid]" class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%" align="left"> <tr> <if condition="$post['field6']"><td id="field6" class="vbmenu_control"><a href="$show[nojs_link]#field6">PS2 Gamertag</a><script type="text/javascript"> vbmenu_register("field6"); </script></td></if> </tr> </table> Code:
<!-- MY CUSTOM MENU --> <div class="vbmenu_popup" id="field6_menu" style="display:none"> <table cellpadding="4" cellspacing="1" border="0"> <tr> <td class="thead"><div class="smallfont">PS2 Gamer Tag: $post[field6]</div></td> </tr> </table> </div> <!-- / MY CUSTOM MENU --> Here is an example of what I am trying to achieve(click the PS2 Gamertag link): http://www.eahockey.com/forums/showt...=9907#post9907 (no registration necassary) Thanks in advance |
#7
|
|||
|
|||
try using $userinfo[field6] instead.
|
#8
|
|||
|
|||
No luck on that peterska2.
I might have done more wrong, as if I go to some other pages the dropdown does not function at all. |
#9
|
|||
|
|||
help!
i did it on my own, didn't work. looked at this, and duplicated it. i get the link, but no drop down. here's the code: HTML Code:
<if condition="$show['member']"> <td id="techrefmenu" class="vbmenu_control"><a href="$show[nojs_link]#techrefmenu">$vbphrase[tech]</a> <script type="text/javascript"> vbmenu_register("techrefmenu"); </script></td> </if> and: HTML Code:
<div class="vbmenu_popup" id="techrefmenu" style="display:none"> <table cellpadding="4" cellspacing="1" border="0"> <tr><td class="thead">$vbphrase[tech]</td></tr> <tr><td class="vbmenu_option"><a href="e53wd.php">$vbphrase[tech_x5wds]</a></td></tr> <tr><td class="vbmenu_option"><a href="e83wd.php">$vbphrase[tech_x3wds]</a></td></tr> </table> </div> please help! thanks in advance! |
#10
|
|||
|
|||
Replace your second piece of code with
Code:
<div class="vbmenu_popup" id="techrefmenu_menu" style="display:none"> <table cellpadding="4" cellspacing="1" border="0"> <tr><td class="thead">$vbphrase[tech]</td></tr> <tr><td class="vbmenu_option"><a href="e53wd.php">$vbphrase[tech_x5wds]</a></td></tr> <tr><td class="vbmenu_option"><a href="e83wd.php">$vbphrase[tech_x3wds]</a></td></tr> </table> </div> |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|