MDN may have intermittent access issues April 18 13:00 - April 19 01:00 UTC. See whistlepig.mozilla.org for all notifications.

mozilla

Compare Revisions

:checked

Change Revisions

Revision 830:

Revision 830 by McGurk on

Revision 831:

Revision 831 by Dimitar_Bonev on

Title:
:checked
:checked
Slug:
CSS/:checked
CSS/:checked
Tags:
css, "CSS Reference", Selectors
css, "CSS Reference", Selectors
Content:

Revision 830
Revision 831
n14      The <code>:checked</code> <a href="/en/CSS/Pseudo-classes" n14      The <code>:checked</code> <a href="/en/CSS/Pseudo-classes" 
>title="Pseudo-classes">pseudo-class</a> selector represents any r>title="Pseudo-classes">pseudo-class</a> selector represents any <
>adio (<code>&lt;input type="radio"&gt;</code>) or checkbox ({{ HT>strong>radio</strong> (<code>&lt;input type="radio"&gt;</code>)
>MLElement("option") }} in a {{ HTMLElement("select") }}) element ><strong>checkbox&nbsp;</strong>(<code>&lt;input type="checkbox"&g
>that is checked or toggled to an <code>on</code> state. The user >t;</code>) or <strong>option&nbsp;</strong>({{ HTMLElement("optio
>can change this state by clicking on the element, or selecting a >n") }} in a {{ HTMLElement("select") }}) element that is checked 
>different value, in which case the <code>:checked</code> pseudo-c>or toggled to an <code>on</code> state. The user can change this 
>lass no longer applies to this element, but will to the relevant >state by clicking on the element, or selecting a different value,
>one.> in which case the <code>:checked</code> pseudo-class no longer a
 >pplies to this element, but will to the relevant one.
n30        <code>input[type="radio"]:checked</code><code><br></code>n30        <code>input[type="radio"]:checked</code><br>
t36        input[type="checkbox"]:checkedt36        <code>input[type="checkbox"]:checked</code>

Back to History