Javascript Reference
Categories: STYLE

javascript STYLE filter

@Aug. 15, 2009, 12:34 p.m.
filter Firefox/Netscape/NN n/a IE 4(Win) Chrome/Safari/DOM n/a  

 

Read/Write  

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. Although the filter property is present in Internet Explorer for Macintosh, it does not operate there.

 
Example
 
document.getElementById("fancy").style.filter= "dropshadow( )";
 
Value

Each filter property 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. Note that Microsoft instituted an entirely new filter syntax starting with IE 5.5 for Windows. The new syntax runs in parallel with the old (for now).  

 
Default

None.


Powered by Linode.