Export (0) Print
Expand All

Suffix property

Matches the specified suffix of a property value.

[attr$=val] { sRules }

attr

Either an identifier or a string.

val

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 ends with "n":

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

<div class="test" attr="Green">Test for [$=] (Suffix) succeeded.</div>

Community Additions

ADD
Show:
© 2014 Microsoft