![]() |
vB3 Block PHP, CODE and HTML from unregistered users
vB3 Block PHP, CODE and HTML from unregistered visitors v1.1
(By Boofo) What does this hack do? This will block all php, code and html code from all unregistered users. Any code bewteen those tags will be replaced will a line telling them they are not allowed to view the code and to please register. (You can change the messages to whatever you like.) Included is also the code for the QUOTE boxes. I don't use the QUOTE boxes bypass on my board, but I have the option ready in case someone decides to quote code, php or html code to bypass this hack. Anything between the code, php or html tags will be parsed out, even quote tags, as long as it is between one of the other tags within the quote itself. If someone just puts QUOTE tags around the code itself, then it will show as normal (unless you add the quote bypass below). Version Information: Version 1.0 --Initial release Version 1.1 --Updated to now work in the archive. Also added the ability to double-click the code box to copy the code to the clipboard. Only works in IE so far. Will be adding the double-clicking ability for other browers as I find what will work with them. Installation overview: Files to edit: (2) --includes/functions_bbcodeparse.php --archive/index.php Templates to edit: 3 (Optional: 2) --bbcode_code --bbcode_html --bbcode_php (Optional) --bbcode_sql --bbcode_quote Phrases to add: 3 (Optional: 2) --bf2_block_code --bf2_block_html --bf2_block_php (Optional) --bf2_sql_code --bbcode_quote If you find this hack useful, please click the install button. ;) |
Hehe you beat me to porting it. Good to see you back again Bob :)
|
I could never get this to work right before the Gamma. The template conditionals make it so easy now. Would have done it all that way except the global doesn't work in templates (at least I couldn't get it to work there). ;)
|
I run RC1 and it works fine for me. Go through the hack again and make sure you added the stuff to the file.
|
Neat :) I'll definately try this one.
|
Ah, sweet stuff Boofo :D I'm ginna add this to my board too.
*install |
Does this work with post caching?
|
Seems to work fine :)
|
Thank you, Chroder, for verifying that. I don't have post caching enabled but I thought it should work with it. ;)
Don't forget the install button, guys. ;) |
Can this be edited for other bbcode? For example the spoiler one that was recently released, can it be edited along with this so that unregistered users cannot see it?
|
All times are GMT. The time now is 08:33 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|