Moderator Column Javascript Menu
This modification is in the archives.
This hack will change the moderator column previewed on forum home and on subforums into a clickable javascript menu using vBulletin's own menu control API. Each moderator will have it's own column in the menu, and will be a clickable link leading to the moderator's profile page; in addition, there will be a link to allow the user easy access to send a new PM. This hack will automatically use the old style moderator column separated by commas if the viewer's browser has javascript disabled.
Demo: http://www.giveupalready.com/index.php Included in the post is the image for the Send PM button, you will need to place it in your images/buttons directory for it to work. First, find and open up forumhome_forumbit_level1_post and locate: Code:
<if condition="$vboptions['showmoderatorcolumn']"> <td class="alt1"><div class="smallfont">$forum[moderators] </div></td> </if> Code:
<if condition="$vboptions['showmoderatorcolumn']"> <td class="alt1"> <if condition="$show['popups']"> <if condition="$forum[moderators]"> <div id="moderators$forum[forumid]" class="smallfont"> <a href="#"><strong>Moderators</strong></a> <script type="text/javascript"> vbmenu_register("moderators$forum[forumid]"); </script> </div> <div class="vbmenu_popup" id="moderators$forum[forumid]_menu" style="display:none"> <table cellpadding="4" cellspacing="1" border="0"> <tr><td class="thead">$forum[title] Moderators</td></tr> $forum[moderators] </table> </div> </if> <else /> <div class="smallfont">$forum[moderators]</div> </if> </td> </if> Code:
<if condition="$vboptions['showmoderatorcolumn']"> <td class="alt1"><div class="smallfont">$forum[moderators] </div></td> </if> Code:
<if condition="$vboptions['showmoderatorcolumn']"> <td class="alt1"> <if condition="$show['popups']"> <if condition="$forum[moderators]"> <div id="moderators$forum[forumid]" class="smallfont"> <a href="#"><strong>Moderators</strong></a> <script type="text/javascript"> vbmenu_register("moderators$forum[forumid]"); </script> </div> <div class="vbmenu_popup" id="moderators$forum[forumid]_menu" style="display:none"> <table cellpadding="4" cellspacing="1" border="0"> <tr><td class="thead">$forum[title] Moderators</td></tr> $forum[moderators] </table> </div> </if> <else /> <div class="smallfont">$forum[moderators]</div> </if> </td> </if> Code:
<if condition="$show['popups']"> <tr><td class="vbmenu_option"><div class="smallfont" style="float: left" /><a href="member.php?$session[sessionurl]u=$moderator[userid]">$moderator[musername]</a></div><div style="float: right" /><a href="private.php?$session[sessionurl]do=newpm&u=$moderator[userid]" rel="nofollow"><img src="$stylevar[imgdir_button]/sendpm.png" alt="<phrase 1="$moderator[username]">$vbphrase[send_private_message_to_x]</phrase>" border="0" /></a></div></td></tr> <else /> <if condition="$show['comma_leader']">, </if><a href="member.php?$session[sessionurl]u=$moderator[userid]">$moderator[musername]</a> </if> Code:
<img src="$stylevar[imgdir_button]/sendpm.png" alt="<phrase 1="$moderator[username]">$vbphrase[send_private_message_to_x]</phrase>" border="0" /> If you followed these steps correctly, you should now be able to click "Moderators" in the moderator column to open a javascript menu similar to the ones featured in your very own forum. If you want to disable the arrow icon associated with the menu, locate vbmenu_register("moderators$forum[forumid]"); and change it to vbmenu_register("moderators$forum[forumid]",true); - September 15: Added: Send PM link next to moderator username. Download No files for download. Screenshots
|