Posted on 2004-11-15
Last Modified: 2013-11-18
A newbie here :o)

What is the differnece between XSL and XSLT - I know that XSLT is a subset language of XSL but am otherwise confused...

What would the following be:

<xsl:stylesheet version="1.0" xmlns:xsl="">

    <xsl:template match="/">

    <xsl:template match="bookstore">
    <!-- Prices and books -->
            <xsl:apply-templates select="book"/>

    <xsl:template match="book">
            <xsl:attribute name="ISBN">
                <xsl:value-of select="@ISBN"/>
            <price><xsl:value-of select="price"/></price><xsl:text>


It is labeled : Using XSLT and .NET to Manipulate XML Files  but then al elements are xsl:

Thanks for helping clear the confusion!
Question by:mrichmon
    LVL 7

    Accepted Solution

    XSL is bascically made up of two major components: XSLT (Extensible Stylesheet Language Transformations) and XSL-FO (Extensible Stylesheet Language Formatting Objects). Most of the time, everyone uses the more basic XSLT. But when everyone refers to 'XSL', usually they are just generally referring to the stylesheet. That is, generally, if I say, "this is my XSL", it's just like saying, "this is my stylesheet". It really depends on the context of what you are talking about.

    Your above example would be best referred to as a 'stylesheet'. A stylesheet uses the XSLT part of XSL to create rules that govern the way an XML file will be transformed. The 'xsl:' prefix  basically refers to the URI namespace which is, and this is declared at the top. When you write xsl:template, the 'template' belongs to the 'xsl' namespace that you declared. You didn't have to use 'xsl'. You could say something like:

    <hello:stylesheet version="1.0" xmlns:hello="">

    then the stylesheet would look like:

    <hello:stylesheet version="1.0" xmlns:hello="">

        <hello:template match="/">

        <hello:template match="bookstore">
        <!-- Prices and books -->
                <hello:apply-templates select="book"/>

        <hello:template match="book">
                <hello:attribute name="ISBN">
                    <hello:value-of select="@ISBN"/>
                <price><hello:value-of select="price"/></price><hello:text>


    'hello' or 'xsl' is just a meand of defining a prefix to refer to the URI I hope that clears it up. Cheers.
    LVL 35

    Author Comment

    okay that does help a lot.

    One more question then.

    In general would you use an extention of .xsl or .xslt for a a file that turns xml into xhtml display?
    LVL 7

    Expert Comment

    You should use .xsl

    That is the standard extension for a stylesheet that converts an XML into any format that you want.

    LVL 15

    Expert Comment

    i preffer to use XSLT for stylesheet, and .fo for FO documents.

    the one problem with XSLT - is there are no standard mime-mapping for this filetypes in major web servers like Apache and IIS, so some browsers like Mozilla wouldn't interpret this file in a right way. But, probably you would never faced this case :)

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Suggested Solutions

    Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
    Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
    Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…
    The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now