Hi

I am just wondering wether it is possible to change the syntax used for this module? I would most people who use forums will be more comfortable with bbcode like code.

(This should be used in addition to the current syntax - to cover those more comfortable with it, and for legacy purposes.)

Good idea?

Comments

I found the code in video_filter.module in line 78 but I don't know yet how to change the code.
I must try to change the code for other syntax to [video]URL[/video].

ps: sorry for my bad english.

Status:Active» Closed (fixed)

So, I tried to change the code and it's ready, but I don't know because the safty,

##############################################################
## SNIPPED Description: BB-Code [video]URI[/video]
##
## Files To Edit: [PathToModules]/video_filter/video_filter.module
##
## Edit Level: Easy
##############################################################
## Before Adding This SNIPPET To Your File, You Should Back Up All Files Related To This SNIPPET
##############################################################

#
#-----[ OPEN ]------------------------------------------
#
[PathToModules]/video_filter/video_filter.module

#
#-----[ FIND (usually line 78 ) ]------------------------------------------
#
if (preg_match_all('/\[video(\:(.+))?( .+)?\]/isU', $text, $matches_code)) {

#
#-----[ REPLACE WITH ]------------------------------------------
#
if (preg_match_all('/\[video]((.+))?( .+)?\[\/video]/isU', $text, $matches_code)) {

#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM

Maybe somebody can optimise the code.
Vielleicht kann jemand den Code optimieren.

Greets from Germany / Grüße aus Deutschland.

I know this is pretty old, but how would one go about adding the option to use the [video]url[/video] tags as well as the original way?

It would be great if this could be made configurable, I want to use [media]url[/media] as it goes better with the rest of the filters I'm using (and also because I'm going to attempt to implement codecs for services like SoundCloud and Bandcamp - 'video' makes no sense there). Right now the only option is to hack the module, which is kind of nasty. I don't like the idea of having to reapply patches every time I upgrade :p

Version:6.x-2.4» 7.x-3.x-dev
Status:Closed (fixed)» Active