diff options
author | friendica <info@friendica.com> | 2013-06-21 21:39:06 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2013-06-21 21:39:06 -0700 |
commit | 2fbc78e6cdf9ca01c404d1bf539008a4b384964f (patch) | |
tree | 76adedd34de9059b36c6e3f2bba3caf00db7ea10 /include | |
parent | f835737cb7f8174b69145750be11fe4b896e8820 (diff) | |
download | volse-hubzilla-2fbc78e6cdf9ca01c404d1bf539008a4b384964f.tar.gz volse-hubzilla-2fbc78e6cdf9ca01c404d1bf539008a4b384964f.tar.bz2 volse-hubzilla-2fbc78e6cdf9ca01c404d1bf539008a4b384964f.zip |
fix non-embeddable videos by returning plain links
Diffstat (limited to 'include')
-rw-r--r-- | include/bbcode.php | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/include/bbcode.php b/include/bbcode.php index 4f99a8038..a06d8c4d8 100644 --- a/include/bbcode.php +++ b/include/bbcode.php @@ -424,11 +424,14 @@ function bbcode($Text,$preserve_nl = false, $tryoembed = true) { $Text = preg_replace_callback("/\[video\](.*?)\[\/video\]/ism", 'tryoembed', $Text); $Text = preg_replace_callback("/\[audio\](.*?)\[\/audio\]/ism", 'tryoembed', $Text); - } else { - $Text = preg_replace("/\[video\](.*?)\[\/video\]/", '$1', $Text); - $Text = preg_replace("/\[audio\](.*?)\[\/audio\]/", '$1', $Text); } + // if video couldn't be embedded, link to it instead. + + $Text = preg_replace("/\[video\](.*?)\[\/video\]/", '$1', $Text); + $Text = preg_replace("/\[audio\](.*?)\[\/audio\]/", '$1', $Text); + + // html5 video and audio |