Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 Programming Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 05-16-2010, 06:13 PM
Chadi's Avatar
Chadi Chadi is offline
 
Join Date: May 2004
Location: USA
Posts: 2,043
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Problem with Chat trolls

There is someone continually trolling my chat room (under new accounts constantly) somehow and I don't know how he's doing this for the following reasons:

1. new registrations moderated first (he was not approved yet, but "awaiting email activation"
2. Real Chat (software) is set to usergroups 2, 6, 7, and 38 only. Awaiting email activation usergroup as you know is 4.

This is the template I'm using in various places (header, footer, arcade main page for example) that contains the entrance link. Is something wrong here?

Code:
<!-- Media Center Nav -->
<div class="mc_border_out">
  <div class="mc_border_in">

<div id="middlebar">
<a href="http://www.talkjesus.com/arcade.php"><span><img src="/images/media-menu/games.png" alt="Arcade Games" class="img-media-menu" />&nbsp;Arcade</span></a>
<a href="http://www.talkjesus.com/blogs"><span><img src="/images/media-menu/highlight.png" alt="Blogs" class="img-media-menu" />&nbsp;Blogs</span></a>
<if condition="in_array($bbuserinfo['usergroupid'], array(2,6,7,38))">
<a href="http://www.talkjesus.com/misc.php?do=page&template=Chat"><span><img src="/images/media-menu/chat.png" alt="Christian Live Chat" class="img-media-menu" />&nbsp;Live Chat</span></a><else /><a href="http://www.talkjesus.com/forum-rules-ten-commandments/53-talk-jesus-10-commandments-rule.html"><span><img src="/images/media-menu/chat.png" alt="Christian Live Chat" class="img-media-menu" />&nbsp;Live Chat: Disabled (?)</span></a></if>
<a href="http://www.talkjesus.com/album.php"><span><img src="/images/media-menu/folder.png" alt="Member Albums" class="img-media-menu" />&nbsp;Member Albums</span></a>
<a href="http://www.talkjesus.com/gallery/index.php"><span><img src="/images/media-menu/image.png" alt="Photo Gallery" class="img-media-menu" />&nbsp;Photo Gallery</span></a>
<a href="javascript:openRadioAndTV()"><span><img src="/images/media-menu/multimedia.png" alt="Radio Streaming" class="img-media-menu" />&nbsp;Radio</span></a>
</div>
  
  </div>
</div>
<!-- /Media Center Nav -->

<br />
Info:
VB 3.8x
RealChat
Usergroups 2,6,7,38 only allowed.
Reply With Quote
  #2  
Old 05-17-2010, 03:56 AM
Eric's Avatar
Eric Eric is offline
 
Join Date: May 2006
Location: Kentucky
Posts: 792
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If they know the link to the chat, just using a template conditional to hide it won't work. You'll need to have the 'misc.php?do=page&template=Chat' do a check on usergroup. For example:

PHP Code:
if ($_REQUEST['do'] == 'page' AND $_REQUEST['template'] == 'Chat')
{
        if (!
is_member_of($vbulletin->userinfo2,6,7,38))
        {
                
print_no_permission();
        }

Reply With Quote
  #3  
Old 05-17-2010, 11:19 AM
Chadi's Avatar
Chadi Chadi is offline
 
Join Date: May 2004
Location: USA
Posts: 2,043
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks, but confused here.

Where is the full link for chat in your code, and closing if statement?
Reply With Quote
  #4  
Old 05-18-2010, 04:01 PM
Chadi's Avatar
Chadi Chadi is offline
 
Join Date: May 2004
Location: USA
Posts: 2,043
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Would appreciate help here
Reply With Quote
  #5  
Old 09-25-2010, 09:39 AM
Chadi's Avatar
Chadi Chadi is offline
 
Join Date: May 2004
Location: USA
Posts: 2,043
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I would appreciate help on this
Reply With Quote
  #6  
Old 09-25-2010, 10:54 AM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The code above needs to be in a plugin. In the admin control panel under "Plugins & Products" choose "Add New Plugin". I think for "Hook Location", "misc_start" might work. Enter a title like "Chat Permissions" or something, and paste the above code in the "Plugin PHP Code" field. Choose "Yes" next to "Plugin is Active" and then press "Save".
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:58 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03917 seconds
  • Memory Usage 2,214KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_code
  • (1)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (6)post_thanks_box
  • (6)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (6)post_thanks_postbit_info
  • (6)postbit
  • (6)postbit_onlinestatus
  • (6)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete