Hi all, I'm new to xml and xslt. I'm trying to apply a stylesheet to my xml document but I keep getting no stylesheet available.

Here is my code for my XSL document, XML, DTD, and CSS:

XSL:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<style type="text/css">
    <xsl:value-of select="document('Items.css')" disable-output-escaping="yes" />
</style>
<xsl:template match="Items">

<html>
<head><title>Auctions</title></head>
<body>
<xsl:for-each select="item">
<xsl:value-of select="description"/>
<xsl:value-of select="category"/>
<xsl:value-of select="condition"/>
</xsl:for-each>
</body>
</html>
</xsl:template>
</xsl:stylesheet>

XML:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE catalog_auction SYSTEM "Items.dtd">
<?xml-stylesheet type="text/xsl" href="Items.xsl"?>
<start_auction>
<Items>
    <item itemID="4134134">
        <description>Apple Lisa 1</description>
        <category>Computers</category>
        <condition>Used</condition>
    </item>
    <auction>
        <username>
            <name>Pedrum Golriz</name>
            <address>1000 Hilltop Circle</address>
            <email>golrped1@umbc.edu</email>
            <phoneNumber>4832934832</phoneNumber> 
        </username>
        <auctionID>5134134343</auctionID>
        <buyPrice>$2300</buyPrice>
        <auctionPrice>$100</auctionPrice>
        <duration>7 Days</duration>
    </auction>
    <ShipTo>
        <shippingType>Fedex</shippingType>
        <shippingandhandling>$30.00</shippingandhandling>
    </ShipTo>
    <payment>Paypal</payment>
</Items>

<Items>
    <item itemID="413241324">
        <description>Apple iPhone 5</description>
        <category>Phones and Accessories</category>
        <condition>New</condition>
    </item>
    <auction>
        <username>
            <name>James Bond</name>
            <address>1001 Hilltop Circle</address>
            <email>jbond@mi6.co.uk</email>
            <phoneNumber>0070070007</phoneNumber> 
        </username>
        <auctionID>007</auctionID>
        <buyPrice>$800.00</buyPrice>
        <auctionPrice>$00.07</auctionPrice>
        <duration>7 Days</duration>
        </auction>
    <ShipTo>
        <shippingType>DHL</shippingType>
        <shippingandhandling>$87.00</shippingandhandling>
    </ShipTo>
    <payment>Credit card</payment>
</Items>
<Items>
    <item itemID="4710293847">
        <description>iPhone 5 Case</description>
        <category>Phones and Accessories</category>
        <condition>New</condition>
    </item>
    <auction>
        <username>
            <name>Judy Dench</name>
            <address>1002 Hilltop Circle</address>
            <email>dench1@mi6.co.uk</email>
            <phoneNumber>0194834938</phoneNumber> 
        </username>
        <auctionID>48147893</auctionID>
        <buyPrice>$7.00</buyPrice>
        <auctionPrice>$6.00</auctionPrice>
        <duration>5 Days</duration>
        </auction>
    <ShipTo>
        <shippingType>USPS</shippingType>
        <shippingandhandling>$3.00</shippingandhandling>
    </ShipTo>
    <payment>Credit Card</payment>
</Items>
<Items>
    <item itemID="41341349">
        <description>Transformers DVD</description>
        <category>Movies</category>
        <condition>Used</condition>
    </item>
    <auction>
        <username>
            <name>Chandler Bing</name>
            <address>1013 Hilltop Circle</address>
            <email>bing@yahoo.com</email>
            <phoneNumber>4105839344</phoneNumber> 
        </username>
        <auctionID>41347943</auctionID>
        <buyPrice>$14.00</buyPrice>
        <auctionPrice>$9.00</auctionPrice>
        <duration>3 Day</duration>
        </auction>
    <ShipTo>
        <shippingType>USPS</shippingType>
        <shippingandhandling>Free</shippingandhandling>
    </ShipTo>
    <payment>Credit Card</payment>
</Items>
<Items>
    <item itemID="I8">
        <description>Dropout Year CD</description>
        <category>Music</category>
        <condition>New</condition>
    </item>
    <auction>
        <username>
            <name>Adam Jones</name>
            <address>2 All Star Ave, San Diego, CA 53068</address>
            <email>jones@gmail.com</email>
            <phoneNumber>410-554-6835</phoneNumber>   
        </username>
        <auctionID>#56785459</auctionID>
        <buyPrice>$45.97</buyPrice>
        <auctionPrice>$44.99</auctionPrice>
        <duration>12 Hours</duration>
        </auction>         
    <ShipTo>
        <shippingType>USPS</shippingType>
        <shippingandhandling>$9.99</shippingandhandling>
    </ShipTo>
    <payment>Credit Card</payment>
</Items>
</start_auction>

DTD:

<!--Item Deetails-->
<!ELEMENT start_auction (Items+)>
<!ELEMENT Items (item,auction,ShipTo,payment)>
<!ELEMENT Item (description,category,condition)>
<!ELEMENT description (#PCDATA)>
<!ELEMENT category (#PCDATA)>
<!ELEMENT condition (#PCDATA)>
<!ATTLIST item itemID CDATA #REQUIRED>
<!--Auction Details-->
<!ELEMENT auction (username,auctionID,buyPrice,auctionPrice,duration)>
<!ELEMENT auctionID (#PCDATA)>
<!ELEMENT buyPrice (#PCDATA)>
<!ELEMENT auctionPrice (#PCDATA)>
<!ELEMENT duration (#PCDATA)>
<!--User Details-->
<!ELEMENT username (name,address,email,phoneNumber)>
<!ELEMENT name (#PCDATA)>
<!ELEMENT address (#PCDATA)>
<!ELEMENT email (#PCDATA)> 
<!ELEMENT phoneNumber (#PCDATA)> 
<!--Shipping Details-->
<!ELEMENT ShipTo (shippingType,SandH)>
<!ELEMENT shippingType (#PCDATA)>
<!ELEMENT shippingandhandling (#PCDATA)>
<!--Payment Details..-->
<!ELEMENT payment (#PCDATA)>

and Finally CSS:

<!--/*--><root><![CDATA[<!--/--> 
start_auction {
    margin-left: 15px;
    margin-right: 15px;
    margin-bottom: 15px;
    background-image: linear-gradient(bottom, rgb(129,235,235) 38%, rgb(166,255,248) 69%, rgb(138,219,219) 85%);
    background-image: -o-linear-gradient(bottom, rgb(129,235,235) 38%, rgb(166,255,248) 69%, rgb(138,219,219) 85%);
    background-image: -moz-linear-gradient(bottom, rgb(129,235,235) 38%, rgb(166,255,248) 69%, rgb(138,219,219) 85%);
    background-image: -webkit-linear-gradient(bottom, rgb(129,235,235) 38%, rgb(166,255,248) 69%, rgb(138,219,219) 85%);
    background-image: -ms-linear-gradient(bottom, rgb(129,235,235) 38%, rgb(166,255,248) 69%, rgb(138,219,219) 85%);

    background-image: -webkit-gradient(
        linear,
        left bottom,
        left top,
        color-stop(0.38, rgb(129,235,235)),
        color-stop(0.69, rgb(166,255,248)),
        color-stop(0.85, rgb(138,219,219))
    );
    padding-bottom: 20px;
}

Items{
    font-size:14px;
    width:500px;
}

name{
    font-size:20px;
}

category {
    font-size:20px;
    background-image: linear-gradient(bottom, rgb(129,156,235) 38%, rgb(168,220,255) 69%, rgb(139,208,217) 85%);
background-image: -o-linear-gradient(bottom, rgb(129,156,235) 38%, rgb(168,220,255) 69%, rgb(139,208,217) 85%);
background-image: -moz-linear-gradient(bottom, rgb(129,156,235) 38%, rgb(168,220,255) 69%, rgb(139,208,217) 85%);
background-image: -webkit-linear-gradient(bottom, rgb(129,156,235) 38%, rgb(168,220,255) 69%, rgb(139,208,217) 85%);
background-image: -ms-linear-gradient(bottom, rgb(129,156,235) 38%, rgb(168,220,255) 69%, rgb(139,208,217) 85%);

background-image: -webkit-gradient(
    linear,
    left bottom,
    left top,
    color-stop(0.38, rgb(129,156,235)),
    color-stop(0.69, rgb(168,220,255)),
    color-stop(0.85, rgb(139,208,217))
);
}

condition{
    font-family:serif;
    font-size:20px;
    color:black;
    background-image: linear-gradient(bottom, rgb(129,235,136) 38%, rgb(168,255,181) 69%, rgb(141,217,156) 85%);
background-image: -o-linear-gradient(bottom, rgb(129,235,136) 38%, rgb(168,255,181) 69%, rgb(141,217,156) 85%);
background-image: -moz-linear-gradient(bottom, rgb(129,235,136) 38%, rgb(168,255,181) 69%, rgb(141,217,156) 85%);
background-image: -webkit-linear-gradient(bottom, rgb(129,235,136) 38%, rgb(168,255,181) 69%, rgb(141,217,156) 85%);
background-image: -ms-linear-gradient(bottom, rgb(129,235,136) 38%, rgb(168,255,181) 69%, rgb(141,217,156) 85%);

background-image: -webkit-gradient(
    linear,
    left bottom,
    left top,
    color-stop(0.38, rgb(129,235,136)),
    color-stop(0.69, rgb(168,255,181)),
    color-stop(0.85, rgb(141,217,156))
);
}

description{
    font-size:20px;
    background-image: linear-gradient(bottom, rgb(158,128,157) 38%, rgb(168,175,255) 69%, rgb(141,148,217) 85%);
background-image: -o-linear-gradient(bottom, rgb(158,128,157) 38%, rgb(168,175,255) 69%, rgb(141,148,217) 85%);
background-image: -moz-linear-gradient(bottom, rgb(158,128,157) 38%, rgb(168,175,255) 69%, rgb(141,148,217) 85%);
background-image: -webkit-linear-gradient(bottom, rgb(158,128,157) 38%, rgb(168,175,255) 69%, rgb(141,148,217) 85%);
background-image: -ms-linear-gradient(bottom, rgb(158,128,157) 38%, rgb(168,175,255) 69%, rgb(141,148,217) 85%);

background-image: -webkit-gradient(
    linear,
    left bottom,
    left top,
    color-stop(0.38, rgb(158,128,157)),
    color-stop(0.69, rgb(168,175,255)),
    color-stop(0.85, rgb(141,148,217))
);
    width: 400px;
}

ShipTo{
    font-size:20px;
    color:black;
}
email {
    border-bottom: 1px solid black;
    color: blue;
}

username{
    font-family:serif;
    font-size:20px;
    color:black;
}

buyPrice{
    font-family:serif;
    font-size:20px;
    color:black;
    display:block;
}
auctionPrice{
    font-family:serif;
    font-size:20px;
    color:black;
    display:block;
}

auctionID{
    display:block;
    font-family:serif;
    font-size:20px;
    color:black;
}

duration{
    display:block;
    font-family:serif;
    font-size:20px;
    color:black;
}

shippingType{
    display:block;
    color:black;
}

address{
    font-family:serif;
    font-size:20px;
    color:black;
    display:block;
}
item{
    font-family:serif;
    font-size:28px;
    display:inline-block;
}

shippingandhandling {
    font-family:serif;
    font-size:20px;
    color:black;    
}
payment{
    font-family:serif;
    font-size:20px;
    color:black;
    background-color:teal;
}
<!--/-->]]></root><!--*/-->

Thanks in advance!

Forgive me for only skim reading the code quotes as a ton of them, how are you trying to apply the XSL? what language etc? As I see no reference to it in what I skimmed of your above code.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.