diff options
author | Fabio Comuni <fabrix.xm@gmail.com> | 2011-10-24 14:39:39 +0200 |
---|---|---|
committer | Fabio Comuni <fabrix.xm@gmail.com> | 2011-10-24 14:39:39 +0200 |
commit | ac474cf53c28d8fc05eacb1d9076f8c88f1f69ae (patch) | |
tree | cd757db9a4a3d33eeac9b0e4f62703869524fc3e /include/bbcode.php | |
parent | a9fb8e4d6052dbb5db95939128d491897b4f6a0c (diff) | |
download | volse-hubzilla-ac474cf53c28d8fc05eacb1d9076f8c88f1f69ae.tar.gz volse-hubzilla-ac474cf53c28d8fc05eacb1d9076f8c88f1f69ae.tar.bz2 volse-hubzilla-ac474cf53c28d8fc05eacb1d9076f8c88f1f69ae.zip |
try to use oembed on vimeo tag
Diffstat (limited to 'include/bbcode.php')
-rw-r--r-- | include/bbcode.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/bbcode.php b/include/bbcode.php index 81f37ca04..7045f196f 100644 --- a/include/bbcode.php +++ b/include/bbcode.php @@ -172,6 +172,9 @@ function bbcode($Text,$preserve_nl = false) { $Text = preg_replace("/\[youtube\]([A-Za-z0-9\-_=]+)(.*?)\[\/youtube\]/ism", '<iframe width="425" height="350" src="http://www.youtube.com/embed/$1" frameborder="0" ></iframe>', $Text); //} + $Text = preg_replace_callback("/\[vimeo\]https?:\/\/player.vimeo.com\/video\/([0-9]+)(.*?)\[\/vimeo\]/ism",'tryoembed',$Text); + $Text = preg_replace_callback("/\[vimeo\]https?:\/\/vimeo.com\/([0-9]+)(.*?)\[\/vimeo\]/ism",'tryoembed',$Text); + $Text = preg_replace("/\[vimeo\]https?:\/\/player.vimeo.com\/video\/([0-9]+)(.*?)\[\/vimeo\]/ism",'[vimeo]$1[/vimeo]',$Text); $Text = preg_replace("/\[vimeo\]https?:\/\/vimeo.com\/([0-9]+)(.*?)\[\/vimeo\]/ism",'[vimeo]$1[/vimeo]',$Text); $Text = preg_replace("/\[vimeo\]([0-9]+)(.*?)\[\/vimeo\]/ism", '<iframe width="425" height="350" src="http://player.vimeo.com/video/$1" frameborder="0" ></iframe>', $Text); |