problems with code validation when “Alter HTML” is enabled
-
Hello,
in the source code of the site, I see validation errors (on validator.w3) when the plugin is enabled, these options:
switch options to ON: -Alter HTML -Replace <img> tags with <picture> tags, adding the webp to srcset. -Dynamically load picturefill.js on older browsers -Reference webps that haven't been converted yet -Use content filtering hooks (the_content, the_excerpt, etc)
Errors validation:
Error: Element source is missing required attribute srcset. <source data-srcset="/wp-content/webp-express/webp-images/uploads/img.jpg.webp 150w" sizes="(max-width: 286px) 100vw, 286px" type="image/webp"> Error: The sizes attribute may be specified only if the srcset attribute is also present. <source data-srcset="/wp-content/webp-express/webp-images/uploads/img.jpg.webp 150w" sizes="(max-width: 286px) 100vw, 286px" type="image/webp"> Error: Bad value image/svg+xml;charset=utf-8,%3Csvg xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg' viewBox%3D'0 0 280 187'%2F%3E for attribute src on element img: Illegal character in path segment: space is not allowed. <img width="280" height="187" src="image/svg+xml;charset=utf-8,%3Csvg xmlns%3D'http%3A%2F%2Fwww.domain.com/wp-content/uploads/img.jpg 150w" sizes="(max-width: 280px) 100vw, 280px">
and also, if i do not include “Alter HTML”, then the image does not show in the site logo. somewhere incorrectly replaces. it tested in work on The7 template
Viewing 7 replies - 1 through 7 (of 7 total)
Viewing 7 replies - 1 through 7 (of 7 total)
- The topic ‘problems with code validation when “Alter HTML” is enabled’ is closed to new replies.