vBulletin Plugins

[VB] Hide bb_codes for unregistered users vb 5.2 and 5.3.3

Submitted by Riot, , Thread ID: 78300

Thread Closed
Riot
The Legend
Divine
Level:
0
Reputation:
54
Posts:
448
Likes:
54
Credits:
297
04-03-2018, 07:00 AM
#1
It is tested both in VB 5.2 and 5.3.3.

Admincp Languages & Phrases Phrase Manager Add New Phrase
Phrase Type : GLOBAL
Product : vBulletin
Varname : hide_code
Text : Please Login or <a href="register.php">Register</a> to see codes
Go to your Admincp Styles & Templates Style Manager Your Style BB Code Layout Templates

Open bbcode_code will see this code:

Code:
<vb:if condition="$vboptions['codemaxlines']">
{vb:set verticalPadding, 12}
{vb:set horizScrollbarAllowance, 20}
{vb:set blockCssHeight, {vb:math {vb:raw blockheight} * {vb:stylevar bbcode_code_line_height} + {vb:raw verticalPadding} + {vb:raw horizScrollbarAllowance}}}
</vb:if>
<div class="bbcode_container">
<div class="bbcode_description">{vb:rawphrase code}:</div>
<pre class="bbcode_code"<vb:if condition="$vboptions['codemaxlines']"> style="height:{vb:raw blockCssHeight};"</vb:if>>{vb:raw code}</pre>
</div>

Substitute for this one.Always remember that the id of users will be the ones of your forum. (Usually unregistered ID: 1) (For other users you choose who has permission)



Content locked
This content has been locked. Please login or register in order to unlock it.





The same code can be used for html_code and php_code. Changing of course {vb: rawphrase code} for the corresponding one in each case for html {vb: rawphrase html_code} and for php {vb: rawphrase php_code}

RE: [VB] Hide bb_codes for unregistered users vb 5.2 and 5.3.3

jjwil
Closed Account
Level:
0
Reputation:
0
Posts:
5
Likes:
0
Credits:
4
02-01-2020, 05:08 AM
#2
thank you very much for sharing this is very nice of you

RE: [VB] Hide bb_codes for unregistered users vb 5.2 and 5.3.3

Nomii
Newbie
Level:
0
Reputation:
0
Posts:
14
Likes:
0
Credits:
1
13-10-2020, 09:24 AM
#3
thank you very much.I have been looking for it.great share

Users browsing this thread: 1 Guest(s)