HTML Checking for Large Sites
Rocket Validator automatically checks your pages on the W3C Validator.
Bad value X for attribute “height” on element “iframe”: Expected a digit but saw “%” instead.
The <iframe>
element, used to embed another document inside the current document, accepts both attributes width
and height
which must be valid non-negative integers. Percentages are not allowed for these attributes.
Check the iframe spec.
Related W3C validator issues
The <table>
element does not accept a height
attribute. Use CSS instead.
The seamless
attribute was proposed to be included in the HTML5 spec, but it wasn’t finally accepted, so it’s not a valid attribute for <iframe>
.
The width
and height
attributes on <img>
elements expect a digit to specify the dimension in pixels. It should not contain units, letters or percent signs.
You can achieve this using CSS instead, for example:
<!-- Invalid syntax, the height attribute expects only digits -->
<img src="photo.jpg" alt="cat" height="auto" />
<!-- Valid syntax using CSS -->
<img src="photo.jpg" alt="cat" style="height: auto" />
Learn more:
An <iframe>
element allows to embed an HTML document inside another HTML document, and its src
attribute is indicated the source URL of the embedded web page. The src
attribute is a required attribute, so it cannot be blank.
Example:
<iframe src="https://example.com/map.html"></iframe>
Learn more:
The attributes width
and height
of <img>
elements expect a non-negative integer, so an empty string is not allowed. Either define the correct dimension, or remove this attribute.
Learn more:
An <iframe>
element allows to embed an HTML document inside another HTML document, and its src
attribute is indicated the source URL of the embedded web page. The query part of that URL contains one or more space characters, which are not allowed, for example:
<iframe src="https://maps.google.it/maps?q=2700 6th Avenue"></iframe>
You should properly escape all space characters as %20
like this:
<iframe src="https://maps.google.it/maps?q=2700%206th%20Avenue"></iframe>
Learn more:
The attributes width
and height
on <img>
elements define the dimensions of the image in CSS pixels, and expect a non-negative integer.
Learn more:
The <iframe>
element, used to embed another document inside the current document, accepts both attributes width
and height
which must be valid non-negative integers. Percentages are not allowed for these attributes.
Check the iframe spec.
The width
and height
attributes on <img>
and <iframe>
elements expect a digit to indicate the number of pixels. Ensure that this attribute contains only digits.
For example:
<!-- This is invalid because width is not a digit -->
<img width="225px" height="100px" alt="cat" src="cat.jpg" />
<!-- This is valid -->
<img width="225" height="100" alt="cat" src="cat.jpg" />
<iframe>
tags are used to embed another document within the current document. To indicate the contents of that nested document, you can either use the src
attribute with an URL, or directly provide the contents with the srcdoc
attribute. Examples:
<!-- This will embed a document by its URL -->
<iframe src="https://example.com"></iframe>
<!-- This will embed the contents provided in the srcdoc attribute -->
<iframe srcdoc="<p>some content</p>"></iframe>
<!-- This is invalid -->
<iframe><p>some content</p></iframe>
50,000 Accessibility and HTML checks per month. Fully automated.
Let our automated scanner check your large sites using Axe Core and W3C Validator.