Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Equality property

Equality property

Exactly matches the specified property value.

[attr=val] { sRules }

attr

Must be either an identifier or a string.

val

Must be either an identifier or a string.

sRules

String that specifies one or more cascading style sheet property/value pairs.

Property selectors are enabled only in standards-compliant mode (strict !DOCTYPE).

Attributes are case-sensitive.

The following style rule selects any property whose value is exactly test-value:

<style>
    .test           {display: none;}
    [attr="test-value"] {display: block;}
</style>

<div class="test" attr="test-value">
    Test for [=] (test-value) succeeded.
</div>

Community Additions

ADD
Show:
© 2015 Microsoft