Publishers of technology books, eBooks, and videos for creative people

Home > Articles > Web Design & Development > Usability

  • Print
  • + Share This
From the author of

9. Table Row Highlights (with JavaScript)

Although CSS is increasingly replacing tables for the basic layout of Web pages, the <table> tag is still the best way to present the content it was originally intended for: tabular data. In fact, tables can greatly benefit from a close association with CSS. Not only can CSS be used for the obvious—defining headers, borders, and row colors but with a bit of DHTML, data tables can be made more useful with rollover effects, so visitors can highlight data along a row.

The table rows alternate dark and light, making them easier to follow.

When the mouse rolls over a row, the background is highlighted.

EXAMPLE:

http://www.webbedenvironments.com/dhtml_css_advanced/code/05_Layout/HighlightTables/index.html

  • + Share This
  • 🔖 Save To Your Account