some more sanitize_rss fixes

This commit is contained in:
Andrew Dolgov 2006-09-21 05:15:52 +01:00
parent 2271e80533
commit 6045287914
2 changed files with 8 additions and 10 deletions

View File

@ -2441,20 +2441,18 @@
}
function sanitize_rss($str) {
$res = "";
$res = $str;
$res = preg_replace('/<script.*?>/i',
"<p class=\"scriptWarn\">", $str);
"<p class=\"scriptWarn\">Disabled script: ", $res);
$res = preg_replace('/<\/script>/i',
"</p>", $res);
$res = preg_replace('/<\/script.*?>/i', "</p>", $res);
$res = preg_replace('/<embed.*?>/i', "", $res);
$res = preg_replace('/<object.*?>.*?<\/object>/i',
"<p class=\"objectWarn\">(Disabled html object
- flash or other embedded content)</p>", $str);
$res = preg_replace('/<\/object>/i',
"</p>", $res);
- flash or other embedded content)</p>", $res);
return $res;
}

View File

@ -1160,9 +1160,9 @@ span.debugTS {
display : none;
}
.scriptWarn:before {
/*.scriptWarn:before {
content : "Disabled script:";
}
}*/
.scriptWarn {
color : white;