vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Forum Jump in Navbar (https://vborg.vbsupport.ru/showthread.php?t=62493)

NTLDR 03-13-2004 10:00 PM

Forum Jump in Navbar
 
This adds a dropdown menu on the navbar which contains all the links found in the forumjump that apears on certain pages. Note the forumjump must be enabled in the ACP for this to work. See the attached screenshot.

In your phpinclude_start template OR in global.php (if you have lots of styles you may want to do one edit to global.php instead of editing styles) after:

PHP Code:

$logincode construct_login_code(); 

Add (or place in the phpinclude_start template, do one or the other):

PHP Code:

$donavjump true;
construct_forum_jump();
$navjump $forumjump;
unset(
$donavjump$forumjump$jumpforumbits$optionselected$usecategories$jumpforumid$jumpforumtitle$curforumid$daysprune$defaultselected); 

Replace the contents of your forumjump template with:

HTML Code:

<if condition="$GLOBALS['donavjump']">
        <!-- navjump menu -->
        <div class="vbmenu_popup" id="navjump_menu" style="display:none">
                <table cellpadding="4" cellspacing="1" border="0">
                        <tr><td class="thead">$vbphrase[site_areas]</td></tr>
                        <tr><td class="vbmenu_option"><a href="forumdisplay.php?$session[sessionurl]forumid=cp">$vbphrase[user_control_panel]</a></td></tr>
                        <tr><td class="vbmenu_option"><a href="forumdisplay.php?$session[sessionurl]forumid=pm">$vbphrase[private_messages]</a></td></tr>
                        <tr><td class="vbmenu_option"><a href="forumdisplay.php?$session[sessionurl]forumid=subs">$vbphrase[subscriptions]</a></td></tr>
                        <tr><td class="vbmenu_option"><a href="forumdisplay.php?$session[sessionurl]forumid=wol">$vbphrase[whos_online]</a></td></tr>
                        <tr><td class="vbmenu_option"><a href="forumdisplay.php?$session[sessionurl]forumid=search">$vbphrase[search_forums]</a></td></tr>
                        <tr><td class="vbmenu_option"><a href="forumdisplay.php?$session[sessionurl]forumid=home">$vbphrase[forums_home]</a></td></tr>       
                        <tr><td class="thead">$vbphrase[forums]</td></tr>       
                        $jumpforumbits
                </table>
        </div>
        <!-- / navjump menu -->
<else />
<div class="smallfont" style="text-align:$stylevar[left]; white-space:nowrap">
        <form action="forumdisplay.php" method="get">
        <input type="hidden" name="s" value="$session[sessionhash]" />
        <input type="hidden" name="daysprune" value="$daysprune" />
        <strong>$vbphrase[forum_jump]</strong><br />
        <select name="f" onchange="this.form.submit();">
                <optgroup label="$vbphrase[site_areas]">
                        <option value="-1" $defaultselected>$vbphrase[please_select_one]</option>
                        <option value="cp" $frmjmpsel[usercp]>$vbphrase[user_control_panel]</option>
                        <option value="pm" $frmjmpsel[pm]>$vbphrase[private_messages]</option>
                        <option value="subs" $frmjmpsel[subs]>$vbphrase[subscriptions]</option>
                        <option value="wol" $frmjmpsel[wol]>$vbphrase[whos_online]</option>
                        <option value="search" $frmjmpsel[search]>$vbphrase[search_forums]</option>
                        <option value="home" $frmjmpsel[home]>$vbphrase[forums_home]</option>
                        <option value="-1">--------------------</option>
                </optgroup>
                <optgroup label="$vbphrase[forums]">
                $jumpforumbits
                </optgroup>
        </select>$gobutton
        </form>
</div>
</if>

Replace the contents of your option template with:

HTML Code:

<if condition="$GLOBALS['donavjump']">
<tr><td class="vbmenu_option"><a href="forumdisplay.php?$session[sessionurl]forumid=$optionvalue">$optiontitle</a></td></tr>
<else />
<option value="$optionvalue" class="$optionclass" $optionselected>$optiontitle</option>
</if>

In your navbar template add:

HTML Code:

<if condition="$vboptions['useforumjump']">
<td id="navjump" class="vbmenu_control"><a href="#navjump">$vbphrase[forum_jump]</a> <script type="text/javascript"> vbmenu_register("navjump"); </script></td>
</if>

Where you want the link to the forum jump to appear.

Still in the navbar template add:

HTML Code:

<if condition="$vboptions['useforumjump']">
$GLOBALS[navjump]
</if>

Before:

HTML Code:

<!-- / NAVBAR POPUP MENUS -->

corsacrazy 03-14-2004 05:53 PM

will it still include forums that we have hidden via acp?

NTLDR 03-14-2004 06:35 PM

It shows exactly what you would see in the forum jump select menu.

sabret00the 03-14-2004 07:40 PM

not bad at all, i was baffled before i saw the screenie, but it looks good, nice work :)

M.C. 03-14-2004 11:38 PM

thanks, gonna try this one ;)

alkatraz 03-15-2004 07:20 AM

awesome hack!!

the3jams 03-15-2004 06:38 PM

Thanks for fulfilling my request. I knew someone would be able to do it :)

[high]* the3jams clicks install[/high]

gmarik 03-15-2004 06:44 PM

nice one, fella!

DrkFusion 03-16-2004 12:21 AM

Excellent work! Not many of the users use Forum Jump, but the feedback and usage of it has been phenominal after the installation of this one.

Chris Blount 03-22-2004 03:27 AM

Works perfectly for me. Thanks!

BarBeQue 04-03-2004 08:48 PM

I installed the sidebar hack by Dark_Wizard.
Now one of the sidebar menu's will be a forum jump menu. Originally i was gonna hardcode all links in that menu, but this sounds sweet.

Gonna see if i can mod it to work in a sidebar instead of as a navbar menu.
Unless you can tell me what to change, that would be a lot easier ;)

BarBeQue 04-06-2004 08:46 AM

hmm still no luck moddign it..

If anyone has an idea, please let me know!

Pitman 05-02-2004 10:00 PM

Is it possible to have sub menus? Like a menu that pop's out of the side of the menu item you roll over, like for sub forums.

NTLDR 05-02-2004 10:09 PM

Not with vBulletin's menu system.

MentaL 05-03-2004 10:04 PM

maybe add section support so it doesnt take up whole screen for those with larger sections =P

Polo 06-22-2004 08:35 PM

What do i need to do to only show parent forums? without the subforums... you see i have alot of sub forums and the list is big... so if anyone knows how to accomplish this please let me know.

PET 06-24-2004 12:31 AM

I'm wondering how this will look for my boards. I have 110 categoryes :)

Polo 06-24-2004 12:17 PM

he he, yeah, i know, that is why i asked is there is a way to show only parent categories, i dont even have 50 and my list drops down big time, having to scroll for a while to see the full list.

b4ne 06-28-2004 10:35 AM

I cannot get the Link to show me all teh forums...

<if condition="$vboptions['useforumjump']">
$GLOBALS[navjump]
</if>

This is the code I need to put into the nav template.... but I dunno where ?

The Link is in the Navbar but If I click on it it doesnt show me the forums

any idea ?

Polo 06-28-2004 12:18 PM

What do i need to do to only show parent forums? without the subforums?

sv1cec 09-21-2004 06:37 AM

Nice hack, just installed it.

However, I noticed that it does not evaluate the permissions of the user, in order to show the proper forums. I have a forum which is viewable only by the admin and the mods and it does not show up in the list.

Of course, neither does the normal Forum Jump, but do you have any idea where that forums list is constructed to see if I can alter it to include admin/mod only forums, depending on the user?

Tnx and congrats
---------
John

Lionel 09-25-2004 04:21 PM

For those of us who have vbadvanced, how do you hardcode the various forums?

cnczone 11-18-2004 03:53 AM

Where do I place to code in the navbar template????

firstimecaller 12-09-2005 11:55 AM

any chance of getting this ported to 3.5.x as a plugin?

prettyboi 01-30-2006 09:57 AM

OMG this is what I have been waiting for. Okay, I understand about the jump forum but is there anyways I can make it to where it just say FORUM instead of Jump Forum?

firstimecaller 01-30-2006 01:10 PM

just change the link text

edit: to do this, change the
Code:

$vbphrase[forum_jump]
with whatever you want it to say

firstimecaller 04-10-2006 08:48 PM

Quote:

Originally Posted by firstimecaller
any chance of getting this ported to 3.5.x as a plugin?

seriously, this is the best implementation of this type of hack I've yet seen. can we get it working for 3.5.x ?

firstimecaller 04-14-2006 08:56 AM

OK, if you are running 3.5.x, seems this works fine if you use the plugin system to put the phpinclude_start part into a global start hook. This template doesn't exist for 3.5.x

enjoy!

nelto 04-21-2006 09:14 PM

Quote:

Originally Posted by firstimecaller
OK, if you are running 3.5.x, seems this works fine if you use the plugin system to put the phpinclude_start part into a global start hook.

Care to explain this a bit more detailed?

Thank you.

firstimecaller 04-21-2006 09:39 PM

Quote:

Originally Posted by nelto
Care to explain this a bit more detailed?

Thank you.

I'll try.

The part that is supposed to go into the phpinclude_start template is:
PHP Code:

$donavjump true;
construct_forum_jump();
$navjump $forumjump;
unset(
$donavjump$forumjump$jumpforumbits$optionselected$usecategories$jumpforumid$jumpforumtitle$curforumid$daysprune$defaultselected); 

so you take that part and make a new plugin

AdminCP>PluginSystem>Plugin Manager
hit link at bottom of page to add new plugin
Leave product as vBulletin
hook location is global_start
give it a title you can remember, like forum menu
then put all the above code in the code box. the rest of the mod you do just like the rest of the instructions.

This change is necessary because the new plugin system in 3.5.x has removed the php_include templates.

Hope that helps

Yahookan 05-09-2006 12:55 PM

Thanks, just amended the relevant templates.

Looks great and worked first time even for a relative n00b.

siraxi 06-13-2006 12:45 AM

Hi

I installed this mod too.

I don't know if it's just the overall style I'm using, but I had to place this code in the header template not in navbar, in order for it to work well.
Quote:

<if condition="$vboptions['useforumjump']">
<td id="navjump"><a href="#navjump">$vbphrase[forum_jump]</a> <script type="text/javascript"> vbmenu_register("navjump"); </script></td>
</if>
Notice that I removed
Quote:

class="vbmenu_control
.

Thanks to all.

imranbaig 11-02-2006 08:15 AM

is there a version similar to this whcih works for 3.62?

imported_infitech 12-03-2006 05:19 AM

Quote:

Originally Posted by imranbaig (Post 1109231)
is there a version similar to this whcih works for 3.62?

BUMP!
3.6.4

ICY ICE 01-02-2007 05:02 AM

anyone? 3.6.4....

I'm trying to do 3 drop/jump menu's from the Navbar.


All times are GMT. The time now is 04:49 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02529 seconds
  • Memory Usage 1,836KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (5)bbcode_html_printable
  • (3)bbcode_php_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (35)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete