vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=236)
-   -   Mini Mods - Mod Dropdown Menu in the Navbar (https://vborg.vbsupport.ru/showthread.php?t=214396)

Sofia 05-22-2009 10:00 PM

Mod Dropdown Menu in the Navbar
 
1 Attachment(s)
This mod allows you to add in the navbar a dropdown menu with modcp links.
This menu is (of course) only available for admins and moderators
It appears only for moderators who have mod link in the footer.


https://vborg.vbsupport.ru/vborg_mis...hreadid=214396





Installation

In the template navbar (or header if you've a customized style with navbar in the header template)


Find:

HTML Code:

<if condition="$show['member']">
<td class="vbmenu_control"><a href="usercp.php$session[sessionurl_q]">$vbphrase[user_cp]</a></td>
        </if>

Add above:

HTML Code:

<if condition="$show['modcplink']"><td id="mod" class="vbmenu_control"><a href="$modcpdir/index.php" accesskey="4" rel="nofollow">Mod</a> <script type="text/javascript"> vbmenu_register("mod"); </script></td></if>


In the template Navbar (or Header),


Find:

HTML Code:

<!-- / PAGENAV POPUP -->
Add below:

HTML Code:

<!-- / Mod menu -->
<if condition="$show['modcplink']">
    <div class="vbmenu_popup" id="mod_menu" style="display:none">
      <table cellpadding="4" cellspacing="1" border="0">
<tr>
<td class="thead">Announcements</td>
</tr>
<tr>
          <td class="vbmenu_option"><a href="$modcpdir/announcement.php?do=add">Post New Announcement</a></td>
</tr>
<tr>
          <td class="thead">Moderation</td>
        </tr>
        <tr>
<td class="vbmenu_option"><a href="$modcpdir/moderate.php?do=posts">Moderate Threads</a></td>
        </tr>
        <tr>
          <td class="vbmenu_option"><a href="$modcpdir/moderate.php?do=posts#posts">Moderate Posts</a></td>
        </tr>
        <tr>
          <td class="vbmenu_option"><a href="$modcpdir/moderate.php?do=attachments">Moderate Attachments</a></td>
        </tr>
        <tr>
          <td class="vbmenu_option"><a href="$modcpdir/moderate.php?do=events">Moderate Events</a></td>
        </tr>
        <tr>
          <td class="vbmenu_option"><a href="$modcpdir/moderate.php?do=messages">Moderate Visitor Messages</a></td>
        </tr>
<tr>
          <td class="thead">Users</td>
        </tr>
        <tr>
          <td class="vbmenu_option"><a href="$modcpdir/user.php?do=find">Search for Users</a></td>
        </tr>
        <tr>
          <td class="vbmenu_option"><a href="$modcpdir/banning.php?do=banuser">Ban Users</a></td>
        </tr>
        <tr>
          <td class="vbmenu_option"><a href="$modcpdir/banning.php?do=modify">View Banned Users</a></td>
        </tr>
        <tr>
          <td class="vbmenu_option"><a href="$modcpdir/user.php?do=doips">Search IP Addresses</a></td>
        </tr>
      </table>
    </div></if>
    <!-- / Mod menu -->

Please click INSTALL if you like this mod.

Enjoy ! :)

DobieGillis? 05-23-2009 10:00 PM

Sofia, you are quickly becoming my favorite coder/designer!

lm3a.net 05-24-2009 04:51 AM

thank you,

Sofia 05-24-2009 09:00 AM

Quote:

Originally Posted by DobieGillis? (Post 1815956)
Sofia, you are quickly becoming my favorite coder/designer!

Thank you, DobieGillis :p

carubmun 06-10-2009 11:15 PM

What about for moderators who dont show in the footer?
Most of my moderators dont show up in the footer at all, but that may be a completely different issue that i have yet to figure out.

sheppardzwc 06-13-2009 05:11 PM

Quote:

Originally Posted by carubmun (Post 1827315)
What about for moderators who dont show in the footer?
Most of my moderators dont show up in the footer at all, but that may be a completely different issue that i have yet to figure out.

You could always use can_moderate() but the menu would still need them to have access to the ModCP, given the reason Sofia used the other variable.

4nawadir.com 06-13-2009 06:54 PM

Great, Thanks
Installed

s-p0k 06-25-2009 04:46 PM

ty
Installed

mabersoft 06-28-2009 09:29 AM

Can i use this on a style i will be making and giving away for free?

Sofia 06-28-2009 10:02 AM

Quote:

Originally Posted by mabersoft (Post 1838749)
Can i use this on a style i will be making and giving away for free?

Hi Mabersoft. Sure, you can ;)


All times are GMT. The time now is 09:20 AM.

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.01269 seconds
  • Memory Usage 1,756KB
  • 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
  • (4)bbcode_html_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete