advertisement
Login | Register   
  Include Code  Search Tips
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   TIP BANK
Browse DevX
Download the code for this article
Partners & Affiliates
advertisement
advertisement
advertisement
advertisement
 

Salvage Your Client-Side JavaScript Menus in ASP.NET Using XML/XSLT

ASP.NET's server-based event-handling model has made working with many popular client-side JavaScript menu systems increasingly unpalatable in their current form. Fortunately, XML and XSLT provide a way out. 


advertisement
or the past several years, creating client-side JavaScript based menus using the browser's DOM capabilities has been a popular way for developers to implement Web site navigation—so popular that there are now hundreds of Web sites offering free or commercial versions of such JavaScript menus. The complexity of such menus ranges from simple boxes that change style when users hover over menu items with the mouse to sophisticated dynamic versions that change content in response to other client-side events.


Despite the range of visual styles and content, these JavaScript-based menus tend to work the same way. The site designer first organizes a menu hierarchy in terms of HTML tags such as <div>, <a>, etc. Each item or group of items contains CSS "class" attributes, which the JavaScript code uses to creates various styles and effects. Extending such menus requires editing the often-cryptic HTML or JavaScript code—or both. Site designers must learn to find their way around the code heuristically to add the new items unless they're willing to spend an excessive amount of time figuring out the entire code and layout scheme.

It's quick, easy and you get access to all the articles on DevX.
This registration/login is to allow you to read articles on devx.com.
Already a member?



advertisement