In Practice
Creating a Navigation Feature
This last example shows how a Web site might use XML and XSLT to support Web-site navigation. For example, a navigation bar on a Web site is a topical list located somewhere on the Web page, usually on the left side of the browser window. Other forms of navigation include the site map. In both cases, hyperlinks are provided that take you to different places on the site.
The idea is that you could use an XML document to maintain the information that goes into this navigation bar. When the site serves a Web page, a script uses the DOM to merge the XML navigation document with the page that’s being served (also an XML document). By maintaining this navigation information in a separate XML document, the ...
Get Special Edition Using XSLT 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.