This topic has not yet been rated - Rate this topic

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>
Did you find this helpful?
(1500 characters remaining)

Community Additions

ADD
© 2013 Microsoft. All rights reserved.