Getting: Element style not allowed as child of element noscript in this context
-
Hi Team
Thanks for the awesome plugin.
While checking HTML errors on our website, we found that one of the errors is coming when we have enabled Lazy loading of images in Autoptimize.
Below is the error we are getting in w3 validator:
- Error:?Element?
style
?not allowed as child of element?noscript
?in this context. (Suppressing further errors from this subtree.)From line?6, column?65380; to line?6, column?65386<noscript><style>.lazyl
Contexts in which element?style
?may be used:Where?metadata content?is expected.In a?noscript
?element that is a child of a?head
?element.Content model for element?noscript
:When?scripting is disabled, in a?head
?element: in any order, zero or more?link
?elements, zero or more?style
?elements, and zero or more?meta
?elements.When?scripting is disabled, not in a?head
?element:?transparent, but there must be no?noscript
?element descendants.Otherwise: text that conforms to the requirements given in the prose.
So far we have been able to understand it is coming from autoptimize > classes > autoptimizeImages.php where below line is present:
echo apply_filters( ‘autoptimize_filter_imgopt_lazyload_cssoutput’, ” );
Can you help us know how to resolve this issue without breaking any other functionalities of Autoptimize. We would like to continue using lazyload for images via your plugin itself.
Thanks in advance!
The page I need help with: [log in to see the link]
- Error:?Element?
- You must be logged in to reply to this topic.