Name

filter — NN n/a IE 4 CSS n/a

Synopsis

Inherited: No

Sets the visual, reveal, or blend filter used to display or change content of an element. A visual filter can be applied to an element to produce effects such as content flipping, glow, drop shadow, and many others. A reveal filter is applied to an element when its visibility changes. The value of the reveal filter determines what visual effect is to be applied to the transition from hidden to shown (or vice versa). This includes effects such as wipes, blinds, and barn doors. A blend filter sets the speed at which a transition between states occurs. As of this writing, the filter attribute is available only in Internet Explorer 4 but does not work in the Macintosh version.

CSS Syntax

filter: filterType1(paramName1=value1, paramName2=value2,...) 
        filterType2(paramName1=value1,...) ...

Value

Each filter attribute may have more than one space-delimited filter type associated with it. Each filter type is followed by a pair of parentheses, which may convey parameters about the behavior of the filter for the current element. A parameter generally consists of a name/value pair, with assignment performed by the equals symbol. See Section , for details on filterType values and parameters.

Initial Value

None.

Example

fastStuff {filter: blur(add=true, direction=225)}

Applies To

BODY, BUTTON, IMG, INPUT, MARQUEE, TABLE, TD, TEXTAREA, TFOOT, TH, THEAD, TR, and absolute-positioned DIV and SPAN elements.

Object Model Reference

IE

[window.]document.all. ...

Get Dynamic HTML: The Definitive Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.