]> git.mxchange.org Git - friendica.git/commitdiff
Remove harmful HTML decode/encode in BBCode::scaleExternalImages
authorHypolite Petovan <hypolite@mrpetovan.com>
Fri, 3 Jan 2020 01:35:59 +0000 (20:35 -0500)
committerHypolite Petovan <hypolite@mrpetovan.com>
Fri, 3 Jan 2020 01:35:59 +0000 (20:35 -0500)
src/Content/Text/BBCode.php

index 11caeb6ecba1c03257ad714af7fabf461924ce1c..4a2a75ece33d9004b1270a8ae21f5d52d017a941 100644 (file)
@@ -444,7 +444,7 @@ class BBCode
                }
 
                // Picture addresses can contain special characters
-               $s = htmlspecialchars_decode($srctext);
+               $s = $srctext;
 
                $matches = null;
                $c = preg_match_all('/\[img.*?\](.*?)\[\/img\]/ism', $s, $matches, PREG_SET_ORDER);
@@ -501,8 +501,6 @@ class BBCode
                        }
                }
 
-               // replace the special char encoding
-               $s = htmlspecialchars($s, ENT_NOQUOTES, 'UTF-8');
                return $s;
        }