Log in

View Full Version : PHP help regarding a "no shouting" function for a specific user


zippokid
04-20-2006, 02:25 AM
So this is basically all pasted from a hack made by Turbosport

https://vborg.vbsupport.ru/showthread.php?t=105348&highlight=shouting


I was wondering if this was the right way to go about disallowing a particular user from shouting in his posts. (I guess we can let him use smilies though)

The file being edited would be: includes/functions_newpost.php

// ###################### user stopshouting #######################
function fetch_no_shouting_text($text)
{
// stops $text being all UPPER CASE
global $vbulletin;
return iif($post['username'] == AnnoyingUser22 AND $text == strtoupper($text) AND strlen($text) >= 3 , ucwords(vbstrtolower($text)), $text);

I'm a little nervous to mess with PHP, so could anyone tell me if this would work, or if such a thing is even possible at all?