Chapter 17. XSLT-Powered Portals and Applications

In this last chapter, we’ll work our way through all of the important capabilities of XSLT in the context of building some interesting Oracle XML applications. By the end of this chapter, I predict you will be an incurable XSLT fanatic as its amazing flexibility transforms you into a more productive developer.

XSLT-Powered Web Store

In this section, we’ll build a simple site for a web store that offers the basic functionality illustrated in Figure 17.1.

Page map of the Everything.com web site

Figure 17-1. Page map of the Everything.com web site

Visitors to the site will be able to see featured items on the home page and can click the name of one of our “shops” to see a home page specific to that shop. They can search the site for a product, and whenever a product appears, they can click a link to see other products by the same manufacturer.

Turning HTML Mockup into an XSLT stylesheet

All product information needs to be displayed consistently across the web store. Our web design team has provided us with an HTML mockup, shown in Figure 17.2, of how each product should look on the site. The HTML file for the mockup is shown in Example 17.1.

Mockup of product display for our web store

Figure 17-2. Mockup of product display for our web store

Example 17-1. Source for HTML Mockup of Product Information

<html> <body> <center> ...

Get Building Oracle XML Applications 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.