miniBB Support Forums | 15 years on The Web
miniBB ®


 | Forums | Register | Reply | Search | Statistics | Manual |
Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications /   

BB Code for text strike-through?

Author Steve Shaw
#1 | Posted: 4 Mar 2014 15:57 
Can we have a BB Code button (Like Bold and Italic) that does a text strike through???



Author Paul
Lead Developer
#2 | Posted: 4 Mar 2014 21:48 
I think it could be done quite easily, replicating existing codes. You will need to draw the button on your own though.

So, for example, take a look in templates/main_post_form.html and replicate the code from let's say the bold tag this way:

<a href="JavaScript:paste_strinL(selektion,3,'[s]','[/s]','')" onmouseover="window.status='{$l_bb_strike}'; return true" onmouseout="window.status=''; return true" onmousemove="pasteSel()"><img src="" style="width:22px;height:22px" alt="{$l_bb_strike}" title="{$l_bb_strike}" /></a>

Put and translate $l_bb_strike into your language pack (lang/eng.php probably).

Then modify bb_codes.php, replicating for the function enCodeBB:


and for the function deCodeBB:


Don't forget about the button, which should be placed under /img/button_strike.gif.

That would be all...

Author Jaime
#3 | Posted: 6 Apr 2014 17:54 
Hi Paul, Yes - That would be all! And it does exactly what it should!

Greetings - Jaime

Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications /
 BB Code for text strike-through?
 Share Topic's Link

Your Reply Click this icon to move up to the quoted message

You are welcome to post anonymously, by entering a nickname with no password (if the similar Username has not been taken yet), or by leaving both fields empty. If you have a forums account, you can also sign in from this page without posting a message, or sign in and post at once.

Before posting, make sure your message is compliant with our forum posting rules. If not, it may be locked or deleted with no explanation.

miniBB Support Forums Powered by Forum Software miniBB ® Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contact Us
Get the Captcha add-on: protect your miniBB-forums from the automated spam and flood.