From: skodak Date: Mon, 11 Dec 2006 22:07:53 +0000 (+0000) Subject: fixed cleantext producing two spaces between element attributes instead of one MDL... X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=049bd7dbbdc09dd9f7911456fd2b58ec28c94739;p=moodle.git fixed cleantext producing two spaces between element attributes instead of one MDL-7894 --- diff --git a/lib/weblib.php b/lib/weblib.php index 6ac2cfdbf4..9c4288cdd0 100644 --- a/lib/weblib.php +++ b/lib/weblib.php @@ -1691,12 +1691,9 @@ function cleanAttributes2($htmlArray){ $arreach['value'] = preg_replace("/j\s*a\s*v\s*a\s*s\s*c\s*r\s*i\s*p\s*t/i", "Xjavascript", $arreach['value']); $arreach['value'] = preg_replace("/e\s*x\s*p\s*r\s*e\s*s\s*s\s*i\s*o\s*n/i", "Xexpression", $arreach['value']); } - $attStr .= ' '.$arreach['name'].'="'.$arreach['value'].'" '; + $attStr .= ' '.$arreach['name'].'="'.$arreach['value'].'"'; } - // Remove last space from attribute list - $attStr = rtrim($attStr); - $xhtml_slash = ''; if (preg_match('%/\s*$%', $attrlist)) { $xhtml_slash = ' /';