Ik moest het ook even moeten opzoeken en heb dit gedaan in een mod om bbcode strike toe te voegen.
Hierin staat beschreven wat je allemaal moet wijzigen en dat is een aardige gids om erachter te komen wat jij dus moet verwijderen. Het is teveel om even te vertellen en daarom plaats ik de mod hier, zodat je zelf kunt achterhalen wat te doen.
Code: Selecteer alles
########################################################
##
## MOD Title: BBcode Strike
## MOD Version: 1.0
## Author: R0cKW|LDeR < da_rockwilder_rw@yahoo.fr >
##
## Description:
## [strike]some text[/strike]
##
## This mod allows you to bar some text as the html tags
## <strike> and </strike>
##
##
## Installation Level: easy
## Installation Time: 5 Minutes
##
## Files To Edit: 5
## - forumroot/includes/bbcode.php
## - forumroot/posting.php
## - forumroot/templates/forumtheme/bbcode.tpl
## - forumroot/language/lang_xxxx/lang_main.php
## - forumroot/includes/posting_body.tpl
##
## Included Files: None
##
########################################################
#
#-----[ ACTION: open ]--------------------------------
#
forumroot/includes/bbcode.php
#
#-----[ ACTION: find ]---------------------------------
#
// [b ] and [/b ] for bolding text.
$text = str_replace("[b:$uid]", $bbcode_tpl['b_open'], $text);
$text = str_replace("[/b:$uid]", $bbcode_tpl['b_close'], $text);
#
#-----[ ACTION: add below ]-------------------------------
#
// [strike] and [/strike] for barring text.
$text = str_replace("[strike:$uid]", $bbcode_tpl['strike_open'], $text);
$text = str_replace("[/strike:$uid]", $bbcode_tpl['strike_close'], $text);
#
#-----[ ACTION: find ]---------------------------------
#
// [b ] and [/b ] for bolding text.
$text = preg_replace("#\[b\](.*?)\[/b\]#si", "[b:$uid]\\1[/b:$uid]", $text);
#
#-----[ ACTION: add below ]----------------------------
#
// [strike] and [/strike] for barring text.
$text = preg_replace("#\[strike\](.*?)\[/strike\]#si", "[strike:$uid]\\1[/strike:$uid]", $text);
#
#-----[ ACTION: save, close, upload ]----------------------------
#
#
#-----[ ACTION: open ]---------------------------------
#
forumroot/templates/forumtheme/bbcode.tpl
#
#-----[ ACTION: find ]---------------------------------
#
<!-- BEGIN b_open -->
<span style="font-weight: bold">
<!-- END b_open -->
<!-- BEGIN b_close -->
</span>
<!-- END b_close -->
#
#-----[ ACTION: add below ]---------------------------------
#
<!-- BEGIN strike_open -->
<span><strike>
<!-- END strike_open -->
<!-- BEGIN strike_close -->
</strike></span>
<!-- END strike_close -->
#
#-----[ ACTION: save, close, upload ]---------------------------------
#
#
#-----[ ACTION: open ]---------------------------------
#
forumroot/languages/lang_xxxx/lang_main.php
#
#-----[ ACTION: find ]---------------------------------
#
$lang['bbcode_f_help'] = "Font size: [size=x-small]small text[/size]";
#
#-----[ ACTION: add below ]---------------------------------
#
$lang['bbcode_k_help'] = "Barring text: [strike]text[/strike] (alt+k)";
#
#-----[ ACTION: save, close, upload ]---------------------------------
#
#
#-----[ ACTION: open ]---------------------------------
#
forumroot/posting.php
#
#-----[ ACTION: find ]---------------------------------
#
"L_BBCODE_F_HELP" => $lang['bbcode_f_help'],
#
#-----[ ACTION: add below ]--------------------------------
#
"L_BBCODE_K_HELP" => $lang['bbcode_k_help'],
#
#-----[ ACTION: save, close, upload ]----------------------------
#
#
#-----[ ACTION: open ]---------------------------------
#
forumroot/templates/forumtheme/posting_body.tpl
#
#-----[ ACTION: find ]---------------------------------
#
f_help = "{L_BBCODE_F_HELP}";
#
#-----[ ACTION: add below ]---------------------------------
#
k_help = "{L_BBCODE_K_HELP}";
#
#-----[ ACTION: find ]---------------------------------
#
bbtags = new Array('[b]','[/b]','[i]','[/i]','[u]','[/u]','[quote]','[/quote]','[code]','
','
','
','[img]','[/img]','
','');
#
#-----[ ACTION: replace with ]---------------------------------
#
bbtags = new Array('
','','
','','
','','[quote]','[/quote]','
','
','
','[img]','[/img]','
','','[strike]','[/strike]');
# NOTE: Other Mods ? Be carefull and just add ( ,'[strike]','[/strike]' ) at the end of the Array...
#
#
#-----[ ACTION: find ]---------------------------------
#
<td><span class="genmed">
<input type="button" class="button" accesskey="w" name="addbbcode16" value="URL" style="text-decoration: underline; width: 40px" onClick="bbstyle(16)" onMouseOver="helpline('w')" />
</span></td>
#
#-----[ ACTION: add below ]---------------------------------
#
<td><span class="genmed">
<input type="button" class="button" accesskey="k" name="addbbcode18" value="Strike" style="width: 40px" onClick="bbstyle(18)" onMouseOver="helpline('k')" />
</span></td>
#
#-----[ ACTION: find ]---------------------------------
#
<select name="addbbcode18" onChange="bbfontstyle('[color=' + this.form.addbbcode18.options[this.form.addbbcode18.selectedIndex].value + ']', '[/color]')" onMouseOver="helpline('s')">
#
#-----[ ACTION: replace with ]---------------------------------
#
<select name="addbbcode20" onChange="bbfontstyle('[color=' + this.form.addbbcode20.options[this.form.addbbcode20.selectedIndex].value + ']', '[/color]')" onMouseOver="helpline('s')">
#
#-----[ ACTION: find ]---------------------------------
#
</select> &{L_FONT_SIZE}:<select name="addbbcode20" onChange="bbfontstyle('[size=' + this.form.addbbcode20.options[this.form.addbbcode20.selectedIndex].value + ']', '[/size]')" onMouseOver="helpline('f')">
#
#-----[ ACTION: replace with ]---------------------------------
#
</select> &{L_FONT_SIZE}:<select name="addbbcode22" onChange="bbfontstyle('[size=' + this.form.addbbcode22.options[this.form.addbbcode22.selectedIndex].value + ']', '[/size]')" onMouseOver="helpline('f')">
#
#-----[ ACTION: save, close, upload ]---------------------------------
#
#
#-----[ EOF ]------------------------------------------
#
[/code]