Am I not allowed to specify the unit for width and height on <img>
tags in HTML5?
I am getting this error from the validator:
Bad value 122px for attribute width on element img: Expected a digit but saw p instead.
Drop the 'px' part. Use only non-negative integers.
Move the percentage width from the html tag to the in-line style:
For example:
Change this line
<iframe width="100%" height="588" style="border:none; background:transparent; overflow:hidden;" />
to this:
<iframe height="588" style="border:none; background:transparent; overflow:hidden; width:100%;" />
then it will validate...
just write 122 instead of 122p
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With