The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Preventing !!!!!!! ???????
Is there any way to knock out multiple punctuation like this??????????????
Damn, I hate posts like this!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Or sentences ~~~~~~~~~~~~~~ full of this. |
#2
|
|||
|
|||
Of course. Use:
$searcharray = array("/([!]*)/si", "/([?]*)/si", "/([~]*)/si"); $replacearray = array("!", "?", "~"); $txt = preg_replace($searcharray, $replacearray, $txt); |
#3
|
|||
|
|||
Thank you for the tools! I'll see if I can apply them properly.
I would presume that functions_newpost.php would be a likely place to insert this. Picking the right spot might be tricky. |
#4
|
|||
|
|||
In functions_bbcodeparse, find:
PHP Code:
PHP Code:
|
#5
|
|||
|
|||
Text entered:
Title: This is a test!!! Results: ~?~!~?~T~?~!~?~h~?~!~?~i~?~!~?~s~?~!~?~ ~?~!~?~i~?~!~?~s~?~!~?~ ~?~!~?~a~?~!~?~ ~?~!~?~t~?~!~?~e~?~!~?~s~?~!~?~t~?~!~?~.~?~!~?~ ~?~!~?~ ~?~!~?~!~?~ ~?~!~?~?~!~?~?~!~?~?~!~?~?~!~?~?~!~?~?~!~?~ ~?~!~?~~?~!~?~~?~!~?~~?~!~?~~?~!~?~~?~!~?~~?~!~?~ If you really look inside the above string, you'll see: This is a test!!! For some reason, it comes back with a string like the above. |
#6
|
|||
|
|||
My code is not supposed to parse those complicated strings of yours.
It is supposed to eliminate "!!!!!!!!!", "??????????" and "~~~~~~~~"... |
#7
|
|||
|
|||
Moved to vB3
|
#8
|
||||
|
||||
This should fix the problem, find inside functions_bbcodeparse.php:
PHP Code:
PHP Code:
After testing the string: Quote:
Quote:
- Zero Tolerance |
#9
|
|||
|
|||
Excellent! Thank you Dark Visor and Zero Tolerance!
|
#10
|
|||
|
|||
What file(s) should I modify in 3.6.5 to have this work?
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|