Invalid HTML Examples


Missing title attribute in abbr.

The USA is a country in North America.


inline [style="…"] detected


Img

img

(Image source omitted)

Figure

The figcaption not first/last child of figure.

Example image
Image description

(This paragraph is :last-child.)

More than one figcaption per figure

Image description
book cover
Image description

Caption is not a child of figure.

This figcaption lacks a figure parent.

Link

External link to non-HTTPS site.

Example link without title

Example link with empty title

Link with target="_blank" that lacks rel="noopener noreferrer".

Example link


List

Invalid child of list.

  1. Valid item within list.

  2. Invalid item within list.

  • li without parent ol or ul.

  • hello
    there

    DL

    dd - Definition list: Definition
    dt - Definition list: Term
    dd - Definition list: Definition

    Invalid item within list.

    dd - Definition list: Definition
    dt - Definition list: Term
    dd - Definition list: Definition

    Invalid item within list.

    dt without correct parent.
    dd without correct parent.
    dt without correct parent.
    dd without correct parent.

    Form

    Radios without name="…"

    This paragraph is :first-child.

    This legend is not :first-child.

    This input lacks type="…"


    Eelement

    Improperly nested div, inside span.

    Improperly nested div, inside p.

    Needless nesting of div tags cannot exceed 3 levels.

    hello world