summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2018-04-17 11:54:37 +0300
committerAndrew Dolgov <[email protected]>2018-04-17 11:54:37 +0300
commit73c432aba5c79809736d82fe28c67f051e09500e (patch)
tree32ec950e1796883ebd5d504a433f602e6db40971
parentd93f0e4be9ebf1c161ac258b7a179d9ab71a8b98 (diff)
fix for new amazing bugs
-rw-r--r--[-rwxr-xr-x]init.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/init.php b/init.php
index e62e353..76969e0 100755..100644
--- a/init.php
+++ b/init.php
@@ -28,11 +28,13 @@ class Af_GoodShowSir extends Plugin {
foreach ($images as $img) {
$src = $img->getAttribute("src");
- if (strpos($src, " ") !== FALSE) {
- $img->setAttribute("src", trim($src));
+ $tmp = trim($src);
+ $tmp = str_replace("%20", "", $tmp);
- $found = true;
+ if ($tmp != $src) {
+ $img->setAttribute("src", $tmp);
+ $found = true;
}
}
}