How to Filter XML Data in XSLT - XSLT Tutorial

Breaking Down XSLT - Part 5

Format
mla apa chicago
Your Citation
Ferrara, Darla. "How to Filter XML Data in XSLT - XSLT Tutorial." ThoughtCo, May. 9, 2017, thoughtco.com/how-to-filter-xml-data-in-xslt-3471511. Ferrara, Darla. (2017, May 9). How to Filter XML Data in XSLT - XSLT Tutorial. Retrieved from https://www.thoughtco.com/how-to-filter-xml-data-in-xslt-3471511 Ferrara, Darla. "How to Filter XML Data in XSLT - XSLT Tutorial." ThoughtCo. https://www.thoughtco.com/how-to-filter-xml-data-in-xslt-3471511 (accessed October 21, 2017).
XML document
XML document. kr7ysztof/Getty Images

XSLT, or XSL Transformations, offers a number of ways to filter data in an XML document and produce an output stream seen by your page viewers. With XSLT, you incorporate a markup language with XPath to discover and disclose information. XML is the carrier that stores the data and XSLT is the display layer. By adding filter elements to a style sheet, you transform your XML into something that a Web browser understands and can accurately display.

XSL:sort

XSLT elements build on each other to filter out details and show only what your reader needs to see. Sort works in partnership with and value-of to generate an output stream based on an XML element. Each element added is a command to search the XML document and locate values.


  
    
    
  
- find XML element and its child
- sort data by style
  
    - display the data in
Bat StylePrice
 
Format
mla apa chicago
Your Citation
Ferrara, Darla. "How to Filter XML Data in XSLT - XSLT Tutorial." ThoughtCo, May. 9, 2017, thoughtco.com/how-to-filter-xml-data-in-xslt-3471511. Ferrara, Darla. (2017, May 9). How to Filter XML Data in XSLT - XSLT Tutorial. Retrieved from https://www.thoughtco.com/how-to-filter-xml-data-in-xslt-3471511 Ferrara, Darla. "How to Filter XML Data in XSLT - XSLT Tutorial." ThoughtCo. https://www.thoughtco.com/how-to-filter-xml-data-in-xslt-3471511 (accessed October 21, 2017).