From dc4aeef20acb6092669905eef1e93b82b1cf9831 Mon Sep 17 00:00:00 2001 From: vChabot Date: Tue, 22 Nov 2011 14:59:30 +0000 Subject: [PATCH] // fix bug from 1.4 --- classes/Media.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/classes/Media.php b/classes/Media.php index e83ab4319..5f7dfe164 100755 --- a/classes/Media.php +++ b/classes/Media.php @@ -105,7 +105,11 @@ class MediaCore preg_match_all('/[a-zA-Z0-9]+=[\"\\\'][^\"\\\']*[\"\\\']/is', $preg_matches[2], $args); $args = $args[0]; sort($args); - $output = $preg_matches[1].' '.implode(' ', $args).'>'; + // if there is no args in the balise, we don't write a space (avoid previous : , now : <title>) + if (empty($args)) + $output = $preg_matches[1].'>'; + else + $output = $preg_matches[1].' '.implode(' ', $args).'>'; return $output; }