Internet Explorer 5 Demos : Striped Tables DHTML Behavior

DescriptionDHTML Behaviors are a new Internet Explorer 5 feature that enable developers to create reusable functionality that can use and extend the object model, and can easily be leveraged by page

ITPro Today

February 18, 2002

1 Min Read
ITPro Today logo in a gray background | ITPro Today

DescriptionDHTML Behaviors are a new Internet Explorer 5 feature that enable developers to create reusable functionality that can use and extend the object model, and can easily be leveraged by page authors. DHTML Behaviors can be used to modify or extend the behavior of existing HTML tags, or to create tags with new functionality.

More Details
In the demo, notice that the script that implements the striped tables effect is encapsulated in a separate file. Also notice that the striped tables behavior extends the object model, exposing two new properties: color1 and color2. To create a striped table, the page author simply adds class=stripes to the table declaration. Optionally, the page author can also specify the colors to be used. If no colors are specified, grey and white are used.

Browser/Platform Compatibility
This DHTML Behaviors sample is supported in Microsoft Internet Explorer 5 on Win32 and Unix platforms.

Usage
Use the proposed new CSS behavior attribute to associate a behavior with a CSS class.

Complete Article

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like