PDA

View Full Version : Exempt Administrators from Shouting Prevention


Kirk Y
06-14-2006, 10:00 PM
Exempt Administrators from SHOUTING Prevention

What does this do?
If you've enabled shouting prevention on your forum's but for whatever reason needed to post a message in all caps or atleast more caps than what you've outlined in the AdminCP as "shouting" -- then this hack is for you.

Details:
Just 1 quick Code Modificiation -- also I should add, that while I didn't look too deeply to see if this were possible with a plugin, I'll keep looking and if I find a way to 'pluginize' this hack, I'll do so.

Instructions:


1. Download the TXT File outlining the file edit -- or if you're too lazy to download, just read below.PLEASE! BACKUP YOUR FUNCTIONS_NEWPOST.PHP FILE -- I AM NOT RESPONSIBLE FOR ANY "UH-OHs" THAT YOU MIGHT MAKE WHILE DOING THIS HACK.Now, with that said, on to the instructions!
--------------------------------------------------------------------


Step 1: Find in includes/functions_newpost.php around line 640.// ###################### Start stopshouting #######################
function fetch_no_shouting_text($text)
{
// stops $text being all UPPER CASE
global $vbulletin;
return iif($vbulletin->options['stopshouting'] AND vbstrlen($text) >= $vbulletin->options['stopshouting'] AND $text == strtoupper($text), ucwords(vbstrtolower($text)), $text);
}


Step 2: Replace this with:// ###################### Start stopshouting #######################
function fetch_no_shouting_text($text)
{
// stops $text being all UPPER CASE
global $vbulletin;
return iif($vbulletin->options['stopshouting'] AND !is_member_of($vbulletin->userinfo, 6) AND vbstrlen($text) >= $vbulletin->options['stopshouting'] AND $text == strtoupper($text), ucwords(vbstrtolower($text)), $text);
}

Step 3: Upload your new file and shout to your heart's desire.

bashy
06-15-2006, 06:52 PM
Cheers m8, installed :)

Snake
06-15-2006, 06:59 PM
Thank you! :)