Throughout the course of my web development learning, I've always had a central problem to deal with. On a typical website, multiple pages have some sort of general, non-changing bits that stay constant throughout the site: headers, footers, and navigational bars are great examples. The only piece that changes regularly, and is arguably the most important piece of a web page, is the central container. How do you keep these two pieces separate on both the frontend and backend of the site? Also, if there are non-changing or simple pieces of a website that do not change from page to page, is there a way to keep them on the client side to keep bandwidth low?
If you work within a framework or templating system, you may work with caching systems to deal with this problem. Outside of this, the most viable solution is XSL, a language designed to parse out and present XML data. XSL can be used on the client or server side - when used on the client side, though, it unlocks a world of possibilities. Browsers treat XSL like a CSS document, downloading it and using it to interpret a document requested from a server.
XSL uses three main tools to read and parse XML. XSLT is a templating language that moves, resorts, and can do basic if/then statements to present XML. XPath can target a specific element or specific group of elements to be used by XSLT. XSL-FO reformats the individual pieces of an XML and can also move and resort a document. Combining these three tools can result in a powerful templating tool that exists on the client side, allowing the client's computer to do the processing and presentation of the website data.
There are few shortcomings to XSL. Some state that the learning curve is sharp, as the language is unique and difficult to easily peruse. Also, some browsers (IE7 and Firefox 2) have specific XSL capabilities that will override website XSL declarations. A good discussion of this problem and a work around can be found here: http://feedme.mind-it.info/. Besides these two problems, though, XSL does promise to be an excellent solution to a web developer with a templating problems and a love for XML.