#################################################################
## Mod Title: Flash BBcode Mod
## Mod Version: 2.0.0
## Author: David Smith davidls14@yahoo.com.au - http://www27.brinkster.com/bb2c
## Description: adds a flash bbcode tag to your forum
##
## Installation Level: easy
## Installation Time: 30 seconds (that's how long it took me)
## Files To Edit: bbcode.tpl bbcode.php
## Included Files: n/a
#################################################################
## Security Disclaimer: This MOD Cannot Be Posted To Or Added At Any Non-Official phpBB Sites without the direct permission of the author
#################################################################
##
## Author Note:
## This mod is ©2002 David Smith, All Rights Reserved
## Be sure to edit all templates you have loaded
##
#################################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
#################################################################
#
#-----[ Open includes/bbcode.phpex ]------------------------------------------
#
#
#-----[ Find ]------------------------------------------
#
$bbcode_tpl['email'] = str_replace('{EMAIL}', '\\1', $bbcode_tpl['email']);
#
#-----[ Add after ]------------------------------------------
#
//Begin Flash Mod Copyright David Smith 2002
$bbcode_tpl['flash'] = str_replace('{WIDTH}', '\\1', $bbcode_tpl['flash']);
$bbcode_tpl['flash'] = str_replace('{HEIGHT}', '\\2', $bbcode_tpl['flash']);
$bbcode_tpl['flash'] = str_replace('{LOOP}', '\\3', $bbcode_tpl['flash']);
$bbcode_tpl['flash'] = str_replace('{URL}', '\\4', $bbcode_tpl['flash']);
#
#-----[ Find ]------------------------------------------
#
// [email]user@domain.tld[/email] code..
$patterns[5] = "#\[email\]([a-z0-9\-_.]+?@[\w\-]+\.([\w\-\.]+\.)?[\w]+)\[/email\]#si";
$replacements[5] = $bbcode_tpl['email'];
#
#-----[ Add after ]------------------------------------------
Note you may need to change array number if used with other BBcode mods
#
// [flash width= height= loop= ] and [/flash] code..
$patterns[7] = "#\[flash width=([0-6]?[0-9]?[0-9]) height=([0-4]?[0-9]?[0-9]) loop=(.*?):$uid\](.*?)\[/flash:$uid\]#si";
$replacements[7] = $bbcode_tpl[flash];
#
#-----[ Find ]------------------------------------------
#
// [img]image_url_here[/img] code..
$text = preg_replace("#\[img\](([a-z]+?)://([^ \n\r]+?))\[/img\]#si", "[img:$uid]\\1[/img:$uid]", $text);
#
#-----[ Add after ]------------------------------------------
#
//[flash width= heigth= loop=] and [/flash]
$text = preg_replace("#\[flash width=([0-6]?[0-9]?[0-9]) height=([0-4]?[0-9]?[0-9]) loop=(.*?)\](([a-z]+?)://([^, \n\r]+))\[\/flash\]#si","[flash width=\\1 height=\\2 loop=\\3:$uid\]\\4[/flash:$uid]", $text);
#
#-----[ Open templates/your template/bbcode.tpl ]------------------------------------------
#
#
#-----[ Find ]------------------------------------------
#
{EMAIL}
#
#-----[ Add after ]------------------------------------------
#
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM