home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  


Book HomeXSLTSearch this book

Chapter 4. Branching and Control Elements

So far, we've done some straightforward transformations and we've been able to do some reasonably sophisticated things. To do truly useful work, though, we'll need to use logic in our stylesheets. In this chapter, we'll discuss the XSLT elements that allow you to do just that. Although you'll see several XML elements that look like constructs from other programming languages, they're not exactly the same. As we go along, we'll discuss what makes XSLT different and how to do common tasks with your stylesheets.

4.1. Goals of This Chapter

By the end of this chapter, you should:

  • Know the XSLT elements used for branching and control

  • Understand the differences between XSLT's branching elements and similar constructs in other programming languages

  • Know how to invoke XSLT templates by name and how to pass parameters to them, if you want

  • Know how to use XSLT variables

  • Understand how to use recursion to get around the "limitations" of XSLT's branching and control elements



Library Navigation Links

Copyright © 2002 O'Reilly & Associates. All rights reserved.