PDA

View Full Version : Show Thread Enhancements - Extra Modoptions into users posts (Ban Link, Edit Avatar, Edit sign,..)


Sofia
23 May 2009, 23:47
Useful. This mod allows you to ban an user directly from his posts. A link appear in the dropwon menu of the member. When you click "Ban this user", it opens a popup window where you can ban ban user of the post. v2: Now you can edit signature, avatar, profilpic


http://www.vbulletin.org/forum/vborg_miscactions.php?do=installhack&threadid=214402



https://www.vbulletin.org/forum/



v2
Special Thanks to SirHappy (http://www.vbulletin.org/forum/member.php?u=208812) for this code (http://www.vbulletin.org/forum/showpost.php?p=1838511&postcount=15)


In the template postbit and postbit_legacy,

Find:


<if condition="$post['userid'] AND $show['member']">
<tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$post"><phrase 1="$post[username]">$vbphrase[add_x_to_contacts]</phrase></a></td></tr>
</if>
[U]

Add below:
<!-- / start - happy extra modoption -->
<if condition="in_array($post, array(2))"><if condition="in_array($bbuserinfo['usergroupid'], array(6))">
<tr><td class="thead"><strong><u>Extra Modoption</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Ban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Unban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Signature from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Avatar from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Profilpic from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><strong>IP-Adress from $post[username]: $post</strong></td></tr></if></if>
<!-- / end - happy extra modoption -->
Modcp Name : If you've rename your modcp folder in your server, please change[I] a href="modcp/ in this code.

[U]First condition : <if condition="in_array($post[usergroupid], array(2))">
Show link in menu of usergroupid specified.
Don't enter admin and mod ID. If you enter "2", ban link appear in the dropdown menu of Members.


Second condition : <if condition="in_array($bbuserinfo['usergroupid'], array(6,7))">
In this example, only admins and moderators are able to view ban link. Pleaser specify usergroup ID who can vien ban link.

v1
** Remove **

Please click INSTALL (http://www.vbulletin.org/forum/vborg_miscactions.php?do=installhack&threadid=214402) if you like this mod.

Enjoy ! :)

Edit by Lynne: 2009-12-12 - The comment line in the code was incorrect - it showed --!> at the end of the comment line and was supposed to be -->. I corrected that in the code above.

understyle
24 May 2009, 00:26
Thanks Sofia!
Nice

lm3a.net
24 May 2009, 05:50
thank you sofia

Sofia
24 May 2009, 09:17
Modification : Now, when you click "Ban this user", it opens a popup window where you can ban ban user of the post.See screenshot ;)

Biker_GA
24 May 2009, 09:47
How similar in code is this in relation to an existing modification located here?
http://www.vbulletin.org/forum/showthread.php?t=133257

Sofia
24 May 2009, 09:54
How similar in code is this in relation to an existing modification located here?
http://www.vbulletin.org/forum/showthread.php?t=133257

Yes, similar mod for 3.6
I didn't see this mod. Sorry. :)

shinng
30 May 2009, 09:37
works great, installed.

GeorgeB85
31 May 2009, 21:25
This code only works for one usergroup. How can you add multiple user groups to it?

GeorgeB85
31 May 2009, 21:26
nevermind....didnt read it enough

Shaheen
01 Jun 2009, 02:42
best mod

nnStaff
01 Jun 2009, 10:21
Nice; I have something similar but rather than "this user" I've used the variable "$post[username]" so that it actually shows their username.

Sofia
03 Jun 2009, 00:26
Nice; I have something similar but rather than "this user" I've used the variable "$post[username]" so that it actually shows their username.

Yes, you can add this variable :)

marshal_ramdev
03 Jun 2009, 03:42
nice ne , thanks

Frank Sinatra
14 Jun 2009, 10:26
thanks sweety, lets try it

SirHappy
27 Jun 2009, 18:49
Thanks Sofia,

I have your code for me extended;)
<!-- / start - happy extra modoption --!>
<tr><td class="thead"><strong><u>Extra Modoption</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Ban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Unban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Signature from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Avatar from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Profilpic from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><strong>IP-Adress from $post[username]: $post[ip]</strong></td></tr>
<!-- / end - happy extra modoption --!> German Translation: Zusätzliche Moderatoroptionen in der Beitragsansicht (http://www.world-of-80s.com/leitfaden-anleitungen-techniken/26675-zusaetzliche-moderatoroptionen-in-der-beitragsansicht.html)

TheMeanBish
27 Jun 2009, 20:15
Thank you Sofia for the edit and SirHappy for the extension. I <3 it

Shevko
27 Jun 2009, 20:45
Best Mod..

Sofia
14 Jul 2009, 23:41
Thanks Sofia,

I have your code for me extended;)
<!-- / start - happy extra modoption --!>
<tr><td class="thead"><strong><u>Extra Modoption</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Ban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Unban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Signature from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Avatar from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Profilpic from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><strong>IP-Adress from $post[username]: $post[ip]</strong></td></tr>
<!-- / end - happy extra modoption --!> German Translation: Zusätzliche Moderatoroptionen in der Beitragsansicht (http://www.world-of-80s.com/leitfaden-anleitungen-techniken/26675-zusaetzliche-moderatoroptionen-in-der-beitragsansicht.html)


Thank you, SirHappy, I'll include it in my first post ;)

flexbuffchest
04 Aug 2009, 00:48
i seem to be having a problem with this. i get the extra mod options to show up for me, but all the users on my forum complain that they can only see the first post in any thread after i install this?:confused:

Itchy Nips
06 Aug 2009, 18:07
i seem to be having a problem with this. i get the extra mod options to show up for me, but all the users on my forum complain that they can only see the first post in any thread after i install this?:confused:

same problem here. I removed the code in the meantime
this problem is with IE only. Users with Firefox did not experience this issue

Gersfan
09 Aug 2009, 20:03
i seem to be having a problem with this. i get the extra mod options to show up for me, but all the users on my forum complain that they can only see the first post in any thread after i install this?:confused:

X3!

I've just found out this problem, had it installed for 2 days,!

CEO254
22 Aug 2009, 01:59
When I use this Mod, the Internet Explorer users can only see the first 2 posts in a thread

Please fix this.....I would love to use this mod

eXoOutsider
23 Aug 2009, 00:34
getting same issue :(

Faizan
24 Aug 2009, 06:01
Nice mod...

Birched
26 Aug 2009, 03:22
Same problem as above (threads cut off). Uninstalled for the time being.

EDIT: Fixed it, reinstalled. The problem is that the html comment tags are wrong: They should be <!-- COMMENT --> instead of <!-- COMMENT --!>; the rest of the page is getting commented out by the non-terminated tags (behaviour is probably browser dependent)

EDIT2: Also, those two conditionals (if... if...) can be made into one statement with an && in it

CEO254
04 Sep 2009, 22:00
Ok, got it to working


GREAT MOD!!!

RTMdotORG
05 Sep 2009, 01:30
This didnt show up at all for me...:(
using 3.8.3

HolyKiller
12 Sep 2009, 20:14
Thanks for mod, but there is a little problem in comment tag.
Like Birched said, comment tag in HTML is NOT <!-- blabla --!> but <!-- blabla -->.

So, remove the second ! or just copy/paste this:


<!-- / start - happy extra modoption -->
<if condition="in_array($post[usergroupid], array(2))"><if condition="in_array($bbuserinfo['usergroupid'], array(6))">
<tr><td class="thead"><strong><u>Extra Modoption</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Ban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Unban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Signature from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Avatar from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Profilpic from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><strong>IP-Adress from $post[username]: $post[ip]</strong></td></tr></if></if>
<!-- / end - happy extra modoption -->



Anyway, i think, better to use 640*480 popup size instead of 500*300, so here is modifed code :)

<!-- / start - happy extra modoption -->
<if condition="in_array($post[usergroupid], array(2))"><if condition="in_array($bbuserinfo['usergroupid'], array(6))">
<tr><td class="thead"><strong><u>Extra Modoption</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=640,height=480,scrollbars=yes')"><strong>Ban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=640,height=480,scrollbars=yes')"><strong>Unban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=640,height=480,scrollbars=yes')"><strong>Edit Signature from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=640,height=480,scrollbars=yes')"><strong>Edit Avatar from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=640,height=480,scrollbars=yes')"><strong>Edit Profilpic from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><strong>IP-Adress from $post[username]: $post[ip]</strong></td></tr></if></if>
<!-- / end - happy extra modoption -->


Enjoy ;)

lordi
14 Sep 2009, 07:30
HolyKiller thanks 100 times man

now it's working

But I will not Install it as the Coder didn't help us

;)

SᴩiDᴇЯ
15 Sep 2009, 22:49
I put it directly after this code in postbit_legacy: is anything wrong in my code?
<if condition="$post['userid'] AND $show['member']">
<tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$post[userid]"><phrase 1="$post[username]">$vbphrase[add_x_to_contacts]</phrase></a></td></tr>
</if>

I copy and pasted this:

<!-- / start - happy extra modoption -->
<if condition="in_array($post[usergroupid], array(2))"><if condition="in_array($bbuserinfo['usergroupid'], array(6))">
<tr><td class="thead"><strong><u>Extra Modoption</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Ban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Unban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Signature from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Avatar from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Profilpic from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><strong>IP-Adress from $post[username]: $post[ip]</strong></td></tr></if></if>
<!-- / end - happy extra modoption -->


The extra modoption didn't show up
using 3.8.4

Simon Lloyd
16 Sep 2009, 00:35
For the second IF rahter than this <if condition="in_array($bbuserinfo['usergroupid'], array(6))"> I used this <if condition="is_member_of($vbulletin->userinfo, array( 5,6))">simply because i understand it better :)

Simon Lloyd
16 Sep 2009, 00:58
You may also want to change this line <tr><td class="vbmenu_option"><strong>IP-Adress from $post[username]: $post[ip]</strong></td></tr> for this one to give a pop up for searching IP's<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=doips&$post[userid]','edit','width=640,height=480,scrollbars=yes')">IP-Adress from $post[username]: $post[ip]</span></td></tr>

SᴩiDᴇЯ
16 Sep 2009, 03:06
For the second IF rahter than this <if condition="in_array($bbuserinfo['usergroupid'], array(6))"> I used this <if condition="is_member_of($vbulletin->userinfo, array( 5,6))">simply because i understand it better :)



You may also want to change this line <tr><td class="vbmenu_option"><strong>IP-Adress from $post[username]: $post[ip]</strong></td></tr> for this one to give a pop up for searching IP's<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=doips&$post[userid]','edit','width=640,height=480,scrollbars=yes')">IP-Adress from $post[username]: $post[ip]</span></td></tr>



I changed both according to your codes and it saved the template with no errors, then i refreshed forum and still no show.....:(

is there anything else that needs changing? although my skin has been coded in a unique way, because my skin is the only one of it's kind in the world. i have had coders take a look and even they say it's been coded in a very complicated way, maybe that has something to do with it.

Simon Lloyd
16 Sep 2009, 03:22
it should have nothing to do with it, if you want to supply your postbit code here i'll help as far as i can.

HolyKiller
16 Sep 2009, 05:44
2 SᴩiDᴇЯ: Check id of your usergroup.

<if condition="in_array($post[usergroupid], array(2))"><if condition="in_array($bbuserinfo['usergroupid'], array(X))">

Change that "X" to number of usergroups which can use this modification.


For example:

<if condition="in_array($post[usergroupid], array(2))"><if condition="in_array($bbuserinfo['usergroupid'], array(5,6,7))">

for Administrators, Supermoderators and Moderators.

SᴩiDᴇЯ
16 Sep 2009, 08:44
it should have nothing to do with it, if you want to supply your postbit code here i'll help as far as i can.

$template_hook[postbit_start]
<table id="post$post[postid]" class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%" align="center">
<tr>
<if condition="$show['announcement']">
<td class="thead" style="font-weight:normal; border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]" colspan="2">
<img class="inlineimg" src="$stylevar[imgdir_statusicon]/post_$post[statusicon].gif" alt="$post[statustitle]" border="0" />
<phrase 1="$post[startdate]" 2="$post[enddate]">$vbphrase[x_until_y]</phrase>
</td>
<else />
<td class="thead" style="font-weight:normal; border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-$stylevar[right]: 0px" $post[scrolltothis]>
<!-- status icon and date -->
<a name="post$post[postid]"><img class="inlineimg" src="$stylevar[imgdir_statusicon]/post_$post[statusicon].gif" alt="$post[statustitle]" border="0" /></a>
$post[postdate]<if condition="!$show['detailedtime']">, $post[posttime]</if>
$post[firstnewinsert]
<!-- / status icon and date -->
</td>
<td class="thead" style="font-weight:normal; border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-$stylevar[left]: 0px" align="$stylevar[right]">
&nbsp;
<if condition="$show['postcount']">#<a href="showpost.php?$session[sessionurl]p=$post[postid]&amp;postcount=$post[postcount]" target="new" rel="nofollow" id="postcount$post[postid]" name="$post[postcount]"><strong>$post[postcount]</strong></a></if>
<if condition="$show['inlinemod']">
<input type="checkbox" name="plist[$postid]" id="plist_$postid" style="vertical-align:middle; padding:0px; margin:0px 0px 0px 5px" value="$post[checkbox_value]" />
</if>
</td>
</if>
</tr>
<tr valign="top">
<td class="alt2" width="205" style="border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-top: 0px; border-bottom: 0px">
<center><img src="images/misc/phead1.gif"></center>
<div class="phead"><center><div id="postmenu_$post[postid]">
<if condition="$show['profile']">
<a class="bigusername" href="member.php?$session[sessionurl]u=$post[userid]">$post[musername]</a>
<script type="text/javascript"> vbmenu_register("postmenu_$post[postid]", true); </script>
<else />
$post[musername]
</if></div><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /></center>

<div class="phead2"><if condition="$post['rank']"><div class="smallfont"><center>$post[rank]</center></div></if>
$template_hook[postbit_userinfo_left]

<center><if condition="$show['avatar']">
<div class="smallfont">
&nbsp;<br /><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$post[avatarurl]" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a>
</div>
</if></center>

<div class="smallfont">
&nbsp;<br />
<div>$WWU002_statblock</div>
<if condition="$post['usertitle']"><center><div><b>Title: </b>$post[usertitle]</div></center></if>
<if condition="$post['joindate']"><div>$vbphrase[join_date]$post[joindate]</div></if>
<div><if condition="$post[field5]">$vbphrase[gender]<img src="$stylevar[imgdir_misc]/$post[field5].png" alt="$post[field5]" /></if></div>
<if condition="$post['field2']"><div>$vbphrase[location_perm]$post[field2]</div></if>
<if condition="$post['age']"><div>$vbphrase[age]$post[age]</div></if>
<div><center>$template_hook[postbit_userinfo_right_after_posts]</center></div>
<if condition="$show['infraction']"><div>$vbphrase[infractions]: $post[warnings]/$post[infractions] ($post[ipoints])</div></if>
<if condition="$show['reputation']"><if condition="$show['reppower']">$vbphrase[reppower]: <span id="reppower_$post[postid]_$post[userid]">$post[reppower]</span> </if><div><span id="repdisplay_$post[postid]_$post[userid]">$post[reputationdisplay]</span></div></if>
$template_hook[postbit_userinfo_right]</div></div><center><img src="images/misc/phead3.gif"></center>

</td>
<if condition="$show['moderated']">
<td class="alt2" id="td_post_$post[postid]" style="border-$stylevar[right]: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]">
<else />
<td class="alt1" id="td_post_$post[postid]" style="border-$stylevar[right]: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]">
</if>
$template_hook[postbit_messagearea_start]
<if condition="$show['messageicon'] OR $post['title']">
<!-- icon and title -->
<div class="smallfont">
<if condition="$show['messageicon']"><img class="inlineimg" src="$post[iconpath]" alt="$post[icontitle]" border="0" /></if>
<if condition="$post['title']"><strong>$post[title]</strong></if>
</div>
<hr size="1" style="color:$stylevar[tborder_bgcolor]; background-color:$stylevar[tborder_bgcolor]" />
<!-- / icon and title -->
</if>

<!-- message -->
<div id="post_message_$post[postid]">
$ad_location[ad_showthread_firstpost_start]
$post[message]
</div>
<!-- / message -->

<if condition="$show['attachments']">
<!-- attachments -->
<div style="padding:$stylevar[cellpadding]px">

<if condition="$show['thumbnailattachment']">
<fieldset class="fieldset">
<legend>$vbphrase[attached_thumbnails]</legend>
<div style="padding:$stylevar[formspacer]px">
$post[thumbnailattachments]
</div>
</fieldset>
</if>

<if condition="$show['imageattachment']">
<fieldset class="fieldset">
<legend>$vbphrase[attached_images]</legend>
<div style="padding:$stylevar[formspacer]px">
$post[imageattachments]
</div>
</fieldset>
</if>

<if condition="$show['imageattachmentlink']">
<fieldset class="fieldset">
<legend>$vbphrase[attached_images]</legend>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
$post[imageattachmentlinks]
</table>
</fieldset>
</if>

<if condition="$show['otherattachment']">
<fieldset class="fieldset">
<legend>$vbphrase[attached_files]</legend>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
$post[otherattachments]
</table>
</fieldset>
</if>

<if condition="$show['moderatedattachment']">
<fieldset class="fieldset">
<legend>$vbphrase[attachments_pending_approval]</legend>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
$post[moderatedattachments]
</table>
</fieldset>
</if>

</div>
<!-- / attachments -->
</if>

$template_hook[postbit_signature_start]
$ad_location[ad_showthread_firstpost_sig]

<if condition="$post['signature']">
<!-- sig -->
<img src="images/misc/sig.gif">
$post[signature]
<!-- / sig -->
</if>

$template_hook[postbit_signature_end]

<if condition="$show['postedited']">
<!-- edit note -->
<div class="smallfont">
<hr size="1" style="color:$stylevar[tborder_bgcolor]; background-color:$stylevar[tborder_bgcolor]" />
<em>
<if condition="$show['postedithistory']">
<phrase 1="$post[edit_username]" 2="$post[edit_date]" 3="$post[edit_time]" 4="posthistory.php?$session[sessionurl]p=$post[postid]">$vbphrase[last_edited_link_by_x_on_y_at_z_postid]</phrase>
<else />
<phrase 1="$post[edit_username]" 2="$post[edit_date]" 3="$post[edit_time]">$vbphrase[last_edited_by_x_on_y_at_z]</phrase>
</if>
<if condition="$post['edit_reason']">
$vbphrase[reason]: $post[edit_reason]
</if>
</em>
</div>
<!-- / edit note -->
</if>

</td>
</tr>
<tr>
<td class="alt2" style="border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-top: 0px">
$post[onlinestatus]
<if condition="$show['reputationlink']">
<span id="reputationmenu_$post[postid]"><a href="reputation.php?$session[sessionurl]p=$post[postid]" rel="nofollow" id="reputation_$post[postid]"><img class="inlineimg" src="$stylevar[imgdir_button]/reputation.gif" alt="<phrase 1="$post[username]">$vbphrase[add_to_xs_reputation]</phrase>" border="0" /></a></span>
<if condition="$show['popups']"><script type="text/javascript"> vbrep_register("$post[postid]")</script></if>
</if>
<if condition="$show['infractionlink']"><a href="infraction.php?$session[sessionurl]do=report&amp;p=$post[postid]" rel="nofollow"><img class="inlineimg" src="$stylevar[imgdir_button]/infraction.gif" alt="<phrase 1="$post[username]">$vbphrase[add_infraction_for_x]</phrase>" border="0" /></a></if>
<if condition="$show['reportlink']"><a href="report.php?$session[sessionurl]p=$post[postid]" rel="nofollow"><img class="inlineimg" src="$stylevar[imgdir_button]/report.gif" alt="$vbphrase[report_bad_post]" border="0" /></a></if>
$post[iplogged]
&nbsp;
</td>
<if condition="$show['moderated']">
<td class="alt2" align="$stylevar[right]" style="border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-$stylevar[left]: 0px; border-top: 0px">
<else />
<td class="alt1" align="$stylevar[right]" style="border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-$stylevar[left]: 0px; border-top: 0px">
</if>
<!-- controls -->
<if condition="$post['editlink']">
<img style="display: none" id="progress_$postid" src="$stylevar[imgdir_misc]/progress.gif" alt="$vbphrase[loading_editor_please_wait]" />
<a href="$post[editlink]" name="vB::QuickEdit::$post[postid]"><img src="$stylevar[imgdir_button]/edit.gif" alt="$vbphrase[edit_delete_message]" border="0" /></a>
</if>
<if condition="$post['forwardlink']">
<a href="$post[forwardlink]"><img src="$stylevar[imgdir_button]/forward.gif" alt="$vbphrase[forward_message]" border="0" /></a>
</if>
<if condition="$post['replylink']">
<a href="$post[replylink]" rel="nofollow"><img src="$stylevar[imgdir_button]/<if condition="$post['forwardlink']">reply_small<else />quote</if>.gif" alt="$vbphrase[reply_with_quote]" border="0" /></a>
</if>
<if condition="$show['multiquote_post']">
<a href="$post[replylink]" rel="nofollow" onclick="return false"><img src="$stylevar[imgdir_button]/multiquote_<if condition="$show['multiquote_selected']">on<else />off</if>.gif" alt="$vbphrase[multi_quote_this_message]" border="0" id="mq_$post[postid]" /></a>
</if>
<if condition="$show['quickreply'] AND !$show['threadedmode']">
<a href="$post[replylink]" rel="nofollow" id="qr_$post[postid]" onclick="return false"><img src="$stylevar[imgdir_button]/quickreply.gif" alt="$vbphrase[quick_reply_to_this_message]" border="0" /></a>
</if>
<if condition="$show['moderated']">
<img src="$stylevar[imgdir_misc]/moderated.gif" alt="$vbphrase[moderated_post]" border="0" />
</if>
<if condition="$show['spam']">
<img src="$stylevar[imgdir_misc]/spam_detected.png" alt="$vbphrase[spam_post]" border="0" />
</if>
<if condition="$show['deletedpost']">
<if condition="$show['managepost']">
<a href="postings.php?$session[sessionurl]do=managepost&amp;p=$post[postid]"><img src="$stylevar[imgdir_misc]/trashcan.gif" alt="$vbphrase[manage]" border="0" /></a>
<else />
<img src="$stylevar[imgdir_misc]/trashcan.gif" alt="$vbphrase[deleted_post]" border="0" />
</if>
</if>
<if condition="$show['redcard']">
<a href="infraction.php?$session[sessionurl]do=view&amp;p=$post[postid]"><img src="$stylevar[imgdir_button]/redcard.gif" alt="$vbphrase[received_infraction]" border="0" /></a>
<else />
<if condition="$show['yellowcard']">
<a href="infraction.php?$session[sessionurl]do=view&amp;p=$post[postid]"><img src="$stylevar[imgdir_button]/yellowcard.gif" alt="$vbphrase[received_warning]" border="0" /></a>
</if>
</if>
$template_hook[postbit_controls]
<!-- / controls -->
</td>
</tr>
</table>
<div class="tcat3"></div>
<br /><br /><br />
$template_hook[postbit_end]

<!-- post $post[postid] popup menu -->
<div class="vbmenu_popup" id="postmenu_$post[postid]_menu" style="display:none">
<table cellpadding="4" cellspacing="1" border="0">
<tr>
<td class="thead">$post[username]</td>
</tr>
<if condition="$show['profile']">
<tr><td class="vbmenu_option"><a href="member.php?$session[sessionurl]u=$post[userid]">$vbphrase[view_public_profile]</a></td></tr>
</if>
<if condition="$show['pmlink']">
<tr><td class="vbmenu_option"><a href="private.php?$session[sessionurl]do=newpm&amp;u=$post[userid]" rel="nofollow"><phrase 1="$post[username]">$vbphrase[send_private_message_to_x]</phrase></a></td></tr>
</if>
<if condition="$show['emaillink']">
<tr><td class="vbmenu_option"><a href="sendmessage.php?$session[sessionurl]do=mailmember&amp;u=$post[userid]" rel="nofollow"><phrase 1="$post[username]">$vbphrase[send_email_to_x]</phrase></a></td></tr>
</if>
<if condition="$show['homepage']">
<tr><td class="vbmenu_option"><a href="$post[homepage]"><phrase 1="$post[username]">$vbphrase[visit_xs_homepage]</phrase></a></td></tr>
</if>
<if condition="$show['search']">
<tr><td class="vbmenu_option"><a href="search.php?$session[sessionurl]do=finduser&amp;u=$post[userid]" rel="nofollow"><phrase 1="$post[username]">$vbphrase[find_more_posts_by_x]</phrase></a></td></tr>
</if>
<if condition="$post['userid'] AND $show['member']">
<tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$post[userid]"><phrase 1="$post[username]">$vbphrase[add_x_to_contacts]</phrase></a></td></tr>
</if>
<!-- / start - happy extra modoption -->
<if condition="in_array($post[usergroupid], array(2))"><if condition="is_member_of($vbulletin->userinfo, array( 5,6))">
<tr><td class="thead"><strong><u>Extra Modoption</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Ban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')"><strong>Unban: $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Signature from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Avatar from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')"><strong>Edit Profilpic from $post[username]</strong></span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=doips&$post[userid]','edit','width=640,height=480,scrollbars=yes')">IP-Adress from $post[username]: $post[ip]</span></td></tr></if></if>
<!-- / end - happy extra modoption -->
$template_hook[postbit_user_popup]
</table>
</div>
<!-- / post $post[postid] popup menu -->

I appreciate any help you can give me Simon.

Thank you in advance.

Simon Lloyd
16 Sep 2009, 11:27
Spider, your postbit is exactly the same as mine in that end section, are you sure you are making the edits to a style you are viewing?

SᴩiDᴇЯ
16 Sep 2009, 15:14
Spider, your postbit is exactly the same as mine in that end section, are you sure you are making the edits to a style you are viewing?

I don't understand about codes, so i have no idea what you are asking me.
Like i said this is a very unique and rare skin
You are welcome to come and check with admin status, at

http://undergroundteam.org

I will be there for another 2 hours from now.

Dingo14
20 Sep 2009, 00:53
can't get this to show in v3.8.3

Simon Lloyd
20 Sep 2009, 06:09
Did you make the changes to the code with regards the "<!-- blah --!>"?

TheSupportForum
20 Sep 2009, 06:41
the only reason why no ip would show in the post you want to ban the user from is very simple

there are many people who use a proxy to access the internet to hide there ip address
vbulletin does not pick up ip address behind some proxy ip address or private ip addresses

for example
i work for a companie that use
equinoxsolutions as there service provider, however to access there internet serivce you are required to input an proxy address in your broswer settings

so if your not seing an ip address related to a post, then this is the reason

if its a different issue please feel free to ask

Dingo14
20 Sep 2009, 09:15
sorted this thanks

need2fart
26 Oct 2009, 05:26
Thank you so much Sofia this is the best mod and makes me feel like forum moderating is so easy. =)

Thank you for making my life so much easier!

bluej
09 Nov 2009, 09:08
not working for me either in 3.8.4

could it have something to do with this mod?
http://www.vbulletin.org/forum/showthread.php?t=207751

Dr.Customs
18 Nov 2009, 10:31
i enhanced this a little bit, its still all the same links
it will only show for admins, but u can add more if u want
and it has better english (no offence)

and i recomend to add it right after
<if condition="$post['userid'] AND $show['member']">
<tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$post[userid]"><phrase 1="$post[username]">$vbphrase[add_x_to_contacts]</phrase></a></td></tr>
</if>



<if condition="$bbuserinfo[usergroupid] == 6">
<tr><td class="thead"><strong><u>Mod Option</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Ban: $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Unban: $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Signature</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Avatar</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Profilpic</span></td></tr>
<tr><td class="vbmenu_option">$post[username]'s IP-Adress: $post[ip]</td></tr></if>

bluej
20 Nov 2009, 03:39
i enhanced this a little bit, its still all the same links
it will only show for admins, but u can add more if u want
and it has better english (no offence)

and i recomend to add it right after
<if condition="$post['userid'] AND $show['member']">
<tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$post[userid]"><phrase 1="$post[username]">$vbphrase[add_x_to_contacts]</phrase></a></td></tr>
</if>



<if condition="$bbuserinfo[usergroupid] == 6">
<tr><td class="thead"><strong><u>Mod Option</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Ban: $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Unban: $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Signature</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Avatar</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Profilpic</span></td></tr>
<tr><td class="vbmenu_option">$post[username]'s IP-Adress: $post[ip]</td></tr></if>

thanks so much this worked great :D

Fastbird
24 Nov 2009, 00:38
Sofia, can you please update your install instructions with the correct info. I installed this today after the fix had been discovered and had been experiencing similar issues. It would be wonderful for anyone coming in after the fixed code to have it correctly.

delfost
02 Dec 2009, 03:31
how i can add more usergroupid ???
Thanks


i enhanced this a little bit, its still all the same links
it will only show for admins, but u can add more if u want
and it has better english (no offence)

and i recomend to add it right after
<if condition="$post['userid'] AND $show['member']">
<tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$post[userid]"><phrase 1="$post[username]">$vbphrase[add_x_to_contacts]</phrase></a></td></tr>
</if>



<if condition="$bbuserinfo[usergroupid] == 6">
<tr><td class="thead"><strong><u>Mod Option</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Ban: $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Unban: $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Signature</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Avatar</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Profilpic</span></td></tr>
<tr><td class="vbmenu_option">$post[username]'s IP-Adress: $post[ip]</td></tr></if>

Simon Lloyd
02 Dec 2009, 04:30
Replace this <if condition="$bbuserinfo[usergroupid] == 6">with this and extend for as many usergroups as you wish <if condition="is_member_of($bbuserinfo,5,6,7)">

delfost
07 Dec 2009, 02:48
Thanks for the answer and working in vbulletin 3.8.4 Patch Level 1


<!-- / Moderacion extra Comieza -->
<if condition="is_member_of($bbuserinfo,5,6)">
<tr><td class="thead"><strong><u>Moderación - Opciones</u></strong></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=640,height=480,scrollbars=yes')">Ban: $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=640,height=480,scrollbars=yes')">Un-Ban: $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=640,height=480,scrollbars=yes')">Editar $post[username]'s Firma</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=640,height=480,scrollbars=yes')">Editar $post[username]'s Avatar</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=640,height=480,scrollbars=yes')">Editar $post[username]'s Foto Perfil</span></td></tr>
<tr><td class="vbmenu_option">$post[username]'s Direccion-IP: $post[ip]</td></tr></if>
<!-- / Moderacion extra Finaliza -->


Btw the code is in spanish :)

Warlord
23 Dec 2009, 02:05
This code looks a bit better if you want it to match the rest of your drop down menu.

<if condition="$show['admincplink']">
<tr>
<td class="thead">Staff Options</td>
</tr>

<tr><td class="vbmenu_option"><a href="misc.php?$session[sessionurl]do=spamcleanconfirm&amp;u=$post[userid]">$vbphrase[spammer_ban_member]</a></td></tr>

<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Ban $post[username]</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Lift $post[username]'s Ban</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/user.php?do=editsig&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Signature </span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/user.php?do=avatar&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Avatar</span></td></tr>
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'"; onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/user.php?do=profilepic&userid=$post[userid]','edit','width=500,height=350,scrollbars=yes')">Edit $post[username]'s Profilepic</span></td></tr>
<tr><td class="vbmenu_option">$post[username]'s IP Address: $post[ip]</td></tr>
</if>

choccyclaire
24 Dec 2009, 01:28
Thanks.

I changed two lines so that the lift ban link does not show for someone who is not banned and vica versa so that the ban link does not show for a banned member:

<if condition="$post[usergroupid]== 2">
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Ban $post[username]</span></td></tr>
</if>
<if condition="$post[usergroupid]== 8">
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Lift $post[username]'s Ban</span></td></tr>
</if>

Warlord
26 Dec 2009, 03:52
Thanks.

I changed two lines so that the lift ban link does not show for someone who is not banned and vica versa so that the ban link does not show for a banned member:

<if condition="$post[usergroupid]== 2">
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Ban $post[username]</span></td></tr>
</if>
<if condition="$post[usergroupid]== 8">
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Lift $post[username]'s Ban</span></td></tr>
</if>

Good idea, not sure why I didn't think of that. One problem though, any users that aren't a member of the usergroup id 2 (Registered Users) or usergroup id 8 (Banned Users) will have neither option appear. If you want to include the ban option to other usergroups (like disgruntled staff members etc).

Change this:

<if condition="$post[usergroupid]== 2">
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Ban $post[username]</span></td></tr>
</if>

To this:

<if condition="$post[usergroupid]!= 8">
<tr><td class="vbmenu_option"><span onmouseover="this.style.textDecoration='underline'";
onmouseout="this.style.textDecoration='none'"; onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]','ban','width=500,height=350,scrollbars=yes')">Ban $post[username]</span></td></tr>

Now one of the two options will appear for everyone.

choccyclaire
06 Jan 2010, 16:57
^ Thanks, did not think of that since I only have default usergroups. :)

chrisvonc
08 Jan 2010, 15:22
Installed without issue. Thank you!

HolyKiller
06 Jul 2010, 13:40
Used on vB3, but is there any update or similar mod for vB4 ?

TheInsaneManiac
30 Nov 2010, 17:24
vB4 Bump =]

TheInsaneManiac
01 Dec 2010, 05:48
I've taken the liberty and ported it to 4.0. The IP Address feature may or may not work. I had to change it a bit due to {vb:raw variable} not being possible to use with conditionals.

4.0 Standards

Find in memberaction_dropdown:
<vb:if condition="$show['emaillink']">
<li class="right">
<img src="{vb:stylevar imgdir_siteicons}/email.png" alt="" />
<a href="sendmessage.php?{vb:raw session.sessionurl}do=mailmember&amp;u={vb:raw memberinfo.userid}" rel='nofollow'>
{vb:rawphrase send_email}
</a>
</li>
</vb:if>

After Add:
<vb:if condition="in_array($bbuserinfo['usergroupid'], array(6,7))">
<li class="left">
<br />
<b>&nbsp;&nbsp;&nbsp;STAFF OPTIONS</b>:
</li>
</vb:if>

<vb:if condition="in_array($bbuserinfo['usergroupid'], array(6,7))">
<li class="left">
<img src="{vb:stylevar imgdir_siteicons}/profile.png" alt="" />
<a href="#" onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=banuser&userid={vb:raw memberinfo.userid}','ban','width=500,height=350,scrollbars=yes')"><strong>Ban {vb:raw memberinfo.username}</strong></a>
</li>
</vb:if>

<vb:if condition="in_array($bbuserinfo['usergroupid'], array(6,7))">
<li class="right">
<img src="{vb:stylevar imgdir_siteicons}/profile.png" alt="" />
<a href="#" onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/banning.php?do=liftban&userid={vb:raw memberinfo.userid}','ban','width=500,height=350,scrollbars=yes')"><strong>Unban {vb:raw memberinfo.username}</strong></a>
</li>
</vb:if>

<vb:if condition="in_array($bbuserinfo['usergroupid'], array(6,7))">
<li class="left">
<img src="{vb:stylevar imgdir_siteicons}/profile.png" alt="" />
<a href="#" onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=editsig&userid={vb:raw memberinfo.userid}','ban','width=500,height=350,scrollbars=yes')"><strong>Edit Signature</strong></a>
</li>
</vb:if>

<vb:if condition="in_array($bbuserinfo['usergroupid'], array(6,7))">
<li class="right">
<img src="{vb:stylevar imgdir_siteicons}/profile.png" alt="" />
<a href="#" onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=avatar&userid={vb:raw memberinfo.userid}','ban','width=500,height=350,scrollbars=yes')"><strong>Edit Avatar</strong></a>
</li>
</vb:if>

<vb:if condition="in_array($bbuserinfo['usergroupid'], array(6,7))">
<li class="left">
<img src="{vb:stylevar imgdir_siteicons}/profile.png" alt="" />
<a href="#" onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=profilepic&userid={vb:raw memberinfo.userid}','ban','width=500,height=350,scrollbars=yes')"><strong>Edit Profile Pic</strong></a>
</li>
</vb:if>

<vb:if condition="in_array($bbuserinfo['usergroupid'], array(6,7))">
<li class="right">
<img src="{vb:stylevar imgdir_siteicons}/profile.png" alt="" />
<a href="#" onmouseover="this.style.cursor='hand';" onClick="window.open('modcp/user.php?do=doips&userid={vb:raw memberinfo.userid}&hash=82d83792b7bfa9c66c304d784b8f1700','ban','width=500,height=350,scrollbars=ye s')"><strong>IP Address</strong></a>
</li>
</vb:if>