aboutsummaryrefslogtreecommitdiffstats
path: root/include/bbcode.php
diff options
context:
space:
mode:
authorFriendika <info@friendika.com>2011-05-22 19:33:35 -0700
committerFriendika <info@friendika.com>2011-05-22 19:33:35 -0700
commit36f14842236a9e515a5cfadafa609a3057cb33d3 (patch)
treeccd0a0868e7e7e05955ab368bc8a677b8b00cc7e /include/bbcode.php
parentb3648de6f066aa25adf4c506001440e16f5914e7 (diff)
parent150830d38c2191d2e55a373043af176208d4b430 (diff)
downloadvolse-hubzilla-36f14842236a9e515a5cfadafa609a3057cb33d3.tar.gz
volse-hubzilla-36f14842236a9e515a5cfadafa609a3057cb33d3.tar.bz2
volse-hubzilla-36f14842236a9e515a5cfadafa609a3057cb33d3.zip
Merge pull request #106 from chriscase/master
Improved Standards Compliance on Some Tags and Fix For Ticket #82.
Diffstat (limited to 'include/bbcode.php')
-rw-r--r--include/bbcode.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/bbcode.php b/include/bbcode.php
index 195fc9181..c2d932674 100644
--- a/include/bbcode.php
+++ b/include/bbcode.php
@@ -90,15 +90,15 @@ function bbcode($Text,$preserve_nl = false) {
// [img=widthxheight]image source[/img]
- $Text = preg_replace("/\[img\=([0-9]*)x([0-9]*)\](.+?)\[\/img\]/", '<img src="$3" height="$2" width="$1">', $Text);
+ $Text = preg_replace("/\[img\=([0-9]*)x([0-9]*)\](.+?)\[\/img\]/", '<img src="$3" style="height:{$2}px; width:{$1}px;" >', $Text);
// Youtube extensions
$Text = preg_replace("/\[youtube\]https?:\/\/www.youtube.com\/watch\?v\=(.+?)\[\/youtube\]/",'[youtube]$1[/youtube]',$Text);
$Text = preg_replace("/\[youtube\]https?:\/\/youtu.be\/(.+?)\[\/youtube\]/",'[youtube]$1[/youtube]',$Text);
- $Text = preg_replace("/\[youtube\](.+?)\[\/youtube\]/", '<iframe width="425" height="349" src="http://www.youtube.com/embed/$1" frameborder="0" allowfullscreen></iframe>', $Text);
+ $Text = preg_replace("/\[youtube\](.+?)\[\/youtube\]/", '<br /><iframe style="width:425px;height:349px;padding:10px 0 10px 0;float:left;" src="http://www.youtube.com/embed/$1" frameborder="0" allowfullscreen></iframe>', $Text);
-// $Text = preg_replace("/\[youtube\](.+?)\[\/youtube\]/", '<object width="425" height="350" type="application/x-shockwave-flash" data="http://www.youtube.com/v/$1" ><param name="movie" value="http://www.youtube.com/v/$1"></param><!--[if IE]><embed src="http://www.youtube.com/v/$1" type="application/x-shockwave-flash" width="425" height="350" /><![endif]--></object>', $Text);
+// $Text = preg_replace("/\[youtube\](.+?)\[\/youtube\]/", '<br /><object style="width:425px;height:350px;" type="application/x-shockwave-flash" data="http://www.youtube.com/v/$1" ><param name="movie" value="http://www.youtube.com/v/$1"></param><!--[if IE]><embed src="http://www.youtube.com/v/$1" type="application/x-shockwave-flash" style="width:425px;height:350px;" /><![endif]--></object>', $Text);
// oembed tag
$Text = oembed_bbcode2html($Text);