Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

Introduction to XSLT


May 28, 2021 XSL T


Table of contents


Introduction to XSLT


In computer science, XSLT is a foreign language abbreviation for extended style sheet translation languages.

T in XSLT stands for "conversion" in English.

XSLT is a language used to convert XML documents to XHTML documents or other XML documents.

XPath is a language used to navigate through XML documents.


The basics you need to have

Before you can continue, you need to have a basic understanding of the following:

  • HTML / XHTML
  • XML / XML namespace
  • Xpath

If you want to learn about these projects first, please visit these tutorials on our home page.


What is XSLT?

  • XSLT means XSL Conversion (XSL Transforms)
  • XSLT is the most important part of XSL
  • XSLT converts one XML document to another
  • XSLT uses XPath to navigate through XML documents
  • XSLT is a W3C standard

XSLT - XSL conversion

XSLT is the most important part of XSL.

XSLT is used to convert one XML document to another, or other types of documents that can be recognized by a browser, such as HTML and XHTML. Typically, XSLT does this by converting each XML element to an (X) HTML element.

With XSLT, you can add elements and properties to the output file, or remove elements and properties from the output file. You can also rearrange and classify elements, perform tests, decide which elements to hide or display, and so on.

A common term for describing the conversion process is that XSLT converts the XML source tree to the XML result tree.


XSLT uses XPath

XSLT uses XPath to find information in XML documents. XPath is used to navigate through elements and properties in XML documents.

If you want to learn XPath first, visit our XPath tutorial.


How does it work?

During the conversion process, XSLT uses XPath to define parts of the source document that match one or more predefined templates. Once the match is found, XSLT converts the matching portion of the source document to the resulting document.


XSLT is a W3C standard

XSLT was established as the W3C standard on November 16, 1999.

For more information about the XSLT activities of W3C, please visit our W3C tutorial.

Starting with the next section, you'll learn more about XSLT!