From: Marcel Werk Date: Sun, 8 Jan 2017 18:41:05 +0000 (+0100) Subject: Fixed amp syntax issues X-Git-Tag: 3.0.0~14 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ada6e5d6b39152bd07a77f3987c42fe81dcdf002;p=GitHub%2FWoltLab%2FWCF.git Fixed amp syntax issues --- diff --git a/wcfsetup/install/files/lib/system/html/output/AmpHtmlOutputProcessor.class.php b/wcfsetup/install/files/lib/system/html/output/AmpHtmlOutputProcessor.class.php index 7f7c338e55..97bb5bf859 100644 --- a/wcfsetup/install/files/lib/system/html/output/AmpHtmlOutputProcessor.class.php +++ b/wcfsetup/install/files/lib/system/html/output/AmpHtmlOutputProcessor.class.php @@ -89,6 +89,19 @@ class AmpHtmlOutputProcessor extends HtmlOutputProcessor { DOMUtil::removeNode($element); } } + + // strip invalid attribute 'style' + /** @var \DOMElement $element */ + foreach ($this->getHtmlOutputNodeProcessor()->getXPath()->query('//*[@style]') as $element) { + $element->removeAttribute('style'); + } + } + + /** + * @inheritDoc + */ + public function getHtml() { + return str_ireplace('getHtmlOutputNodeProcessor()->getHtml()); } /**