MOD Request
Geplaatst: 29 sep 2006, 20:07
Kan iemand deze mod ombouwen voor de bbcode box 5.0 http://www.phpbbhacks.com/viewhack.php?id=1059
Ik weet dat het vaker gebeurt met bijvoorbeeld deze add-on
http://www.phpbbhacks.com/download/6510 was geloof normaal ook een add-on bbcode voor standaard phpbb bbcode.
Code: Selecteer alles
## EasyMod 0.0.6 compliant
#################################################################
## MOD Title: Ra BBcode Mod
## MOD Author: Wing H., David Smith
##(the following codes is base on the modification of David Smith's Flash bbcode)
## MOD Description: adds a stream bbcode tag to your forum for the real player plugin
## the following file formats are supported with the real player plugin:
## ra,ram,rm
## MOD Version: 1.0
##
## Installation Level: easy
## Installation Time: 8 mins
## Files To Edit: includes/bbcode.php
## posting.php
## language/lang_english/lang_main.php
## language/lang_english/lang_bbcode.php
## templates/subSilver/bbcode.tpl
## templates/subSilver/posting_body.tpl
## language/lang_english/lang_bbcode.php
## Included Files: n/a
#################################################################
## For Security Purposes, Please Check: http://www.phpbb.com/mods/downloads/ for the
## latest version of this MOD. Downloading this MOD from other sites could cause malicious code
## to enter into your phpBB Forum. As such, phpBB will not offer support for MOD's not offered
## in our MOD-Database, located at: http://www.phpbb.com/mods/downloads/
#################################################################
##
## Author Notes:
## This mod is c2002 David Smith, All Rights Reserved
## Be sure to edit all templates you have loaded
## Does not show the video object, so you can load and listen to, but not
## view videos.
## This version has autoplay turned off, it can eaisly be turned back on in bbcode.tpl
##
#################################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
#################################################################
#
# IMPORTANT: You MUST first install the Multi Quick BBCode Mod.
#
#
#-----[ OPEN ]------------------------------------------
#
includes/bbcode.php
#
#-----[ FIND ]------------------------------------------
#
$bbcode_tpl['email'] = str_replace('{EMAIL}', '\\1', $bbcode_tpl['email']);
#
#----[ AFTER, ADD ]-----------------------------------------
#
//Begin Strean Mod Copyright David Smith 2002
$bbcode_tpl['ra'] = str_replace('{URL}', '\\1', $bbcode_tpl['ra']);
#
#-----[ FIND ]------------------------------------------
#
$replacements[] = $bbcode_tpl['email'];
#
#----[ AFTER, ADD ]-----------------------------------------
# Note: you may need to change array number if used with other BBcode mods
#
//[ ra ]and[ /ra ]for streaming audio.
$patterns[] = "#\[ra:$uid\](.*?)\[/ra:$uid\]#si";
$replacements[] = $bbcode_tpl['ra'];
#
#-----[ FIND ]------------------------------------------
#
$text = preg_replace("#\[img\]((ht|f)tp://)([^ \?&=\"\n\r\t<]*?(\.(jpg|jpeg|gif|png)))\[/img\]#sie", "'[img:$uid]\\1' . str_replace(' ', '%20', '\\3') . '[/img:$uid]'", $text);
#
#----[ AFTER, ADD ]-----------------------------------------
#
//[ ra]image_url_here[/ra ]code..
$text = preg_replace("#\[ra\](([a-z]+?)://([^, \n\r]+))\[/ra\]#si", "[ra:$uid]\\1[/ra:$uid]", $text);
#
#-----[ OPEN ]---------------------------------
#
posting.php
#
#-----[ FIND ]---------------------------------
#
$EMBB_keys = array(''
$EMBB_widths = array(''
$EMBB_values = array(''
#
#-----[ IN-LINE FIND ]---------------------------------
#
$EMBB_keys = array(''
#
#-----[ IN-LINE AFTER, ADD ]---------------------------------
#
,'r'
#
#-----[ IN-LINE FIND ]---------------------------------
#
$EMBB_widths = array(''
#
#-----[ IN-LINE AFTER, ADD ]---------------------------------
#
,'30'
#
#-----[ IN-LINE FIND ]---------------------------------
#
$EMBB_values = array(''
#
#-----[ IN-LINE AFTER, ADD ]---------------------------------
#
,'ra'
#
#-----[ FIND ]---------------------------------
#
# NOTE: the full line to look for is:
# 'L_BBCODE_F_HELP' => $lang['bbcode_f_help'],
#
'L_BBCODE_F_HELP' =>
#
#-----[ AFTER, ADD ]--------------------------------
#
'L_BBCODE_R_HELP' => $lang['bbcode_r_help'],
##
##
## --- NOTE: You will have to make this change to ALL languages that you ---
## --- plan to support on your board. I use "English" as an example ---
##
##
#
#-----[ OPEN ]---------------------------------
#
language/lang_english/lang_main.php
#
#-----[ FIND ]---------------------------------
#
# NOTE: the full line to look for is:
#$lang['bbcode_f_help'] = "Font size: [size=x-small]small text[/size]";
#
$lang['bbcode_f_help']
#
#-----[ AFTER, ADD ]---------------------------------
#
$lang['bbcode_r_help'] = "ra: [ra]url[/ra] (alt+r)";
#
#-----[ OPEN ]---------------------------------
#
language/lang_english/lang_bbcode.php
#
#-----[ FIND ]---------------------------------
#
# NOTE: the full line to look for is:
# $faq[] = array("How to change the text colour or size", [..SNIP..] </ul>");
#
array("How to change the text colour or size"
#
#-----[ AFTER, ADD ]---------------------------------
#
#TODO: add BBcode faq here
##
##
## --- NOTE: You will have to make this change to ALL themes you have ---
## --- installed. I use "subSilver" as an example. ---
##
##
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/bbcode.tpl
#
#-----[ FIND ]------------------------------------------
#
<!-- BEGIN email --><a href="mailto:{EMAIL}">{EMAIL}</A><!-- END email -->
#
#----[ AFTER, ADD ]-----------------------------------------
#
<!-- BEGIN ra -->
<center><OBJECT ID=video1 CLASSID="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA" HEIGHT=288 WIDTH=352> <PARAM NAME="controls" VALUE="ImageWindow"><PARAM NAME="console" VALUE="Clip1"><PARAM NAME="autostart" VALUE="true"><PARAM NAME="src" VALUE="{URL}"><EMBED SRC="{URL}" type="audio/x-pn-realaudio-plugin" CONSOLE="Clip1" CONTROLS="ImageWindow" HEIGHT=288 WIDTH=352 AUTOSTART=false></OBJECT><br><OBJECT ID=video1 CLASSID="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA" HEIGHT=35 WIDTH=300><PARAM NAME="controls" VALUE="All"> <PARAM NAME="console" VALUE="Clip1"><EMBED type="audio/x-pn-realaudio-plugin" CONSOLE="Clip1" CONTROLS="All" HEIGHT=125 WIDTH=275 AUTOSTART=true></OBJECT></center>
<!-- END ra -->
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/posting_body.tpl
#
#-----[ FIND ]---------------------------------
#
# NOTE: the full line to look for is:
#f_help = "{L_BBCODE_F_HELP}";
#
f_help =
#
#-----[ AFTER, ADD ]------------------------------------------
#
r_help = "{L_BBCODE_R_HELP}";
#-----[ FIND ]---------------------------------
#
# NOTE: the actual line to find is MUCH longer, containing all the bbcode tags
#
bbtags = new Array(
#
#-----[ IN-LINE FIND ]---------------------------------
#
'[url]','[/url]'
#
#-----[ IN-LINE AFTER, ADD ]---------------------------------
#
,'[ra]','[/ra]'
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM
http://www.phpbbhacks.com/download/6510 was geloof normaal ook een add-on bbcode voor standaard phpbb bbcode.