OFFLINE-GmbH / oc-responsive-images-plugin

Adds reponsive images capabilities to October CMS
MIT License
45 stars 26 forks source link

DOM manipulation warning #41

Open educationfutures opened 5 years ago

educationfutures commented 5 years ago

Perhaps this can be attributed to one of the many, wonderful issues I've had in upgrading from php7.2 to php7.3. But, I'm now receiving this warning:

production.WARNING: [OFFLINE.ResponsiveImages] DOM manipulation failed: DOMDocument::loadHTML(): Attribute class redefined in Entity, line: 1 {"exception":"[object] (ErrorException(code: 0): DOMDocument::loadHTML(): Attribute class redefined in Entity, line: 1 at /var/www/plugins/offline/responsiveimages/classes/DomManipulator.php:110)

I'm not quite sure why it's doing that, but since it is a warning, can it be suppressed in a future release?

mpetricek commented 5 years ago

I'm getting the same error. For me it is a problem only on homepage.

mauserrifle commented 4 years ago

I had the same error for a project. For me it was because of the & char in code (non escapaed). For example:

<img .... src="https://www.facebook.com/tr?id=X&ev=PageView&noscript=1">

Should be:

<img ....  src="https://www.facebook.com/tr?id=X&amp;ev=PageView&amp;noscript=1">

So just validate your HTML and fix errors. You should be fine after.