Hi!
I have an issue on my asp page, I have an xml script in there and the only style that is being applied to my xml is the css for the entire site
I did create an xsl file to style the xml but the only way i see that is if I view the xml file outside the asp as an independent file and i see the styles.
What could be wrong?
Here is my XML in my ASP:
Here is the XMLCode:<% //Set the XML Object Set objXML = Server.CreateObject("Microsoft.XMLDOM") //Set Asynchoronous = false objXML.async = False //Load the XML file. //User Server.MapPath method is the XML is located in your site. //Else you can use the absolute path. objXML.Load (Server.MapPath("pbtoc.xml")) //If there is any errors pasring the file the notify If objXML.parseError.errorCode <> 0 Then Response.Write "Error Parsing XML" Response.Write "Reason :" & objXML.parseError.reason & "Error Line: " & objXML.parseError.line End If Set proprietarybrands = objXML.getElementsByTagName(Request.QueryString("id")) //Now Iterate through the List and Display For i = 0 to (proprietarybrands.Length-1) Response.Write pbrands.item(i).childNodes(0).text & ">" Response.Write pbrands.item(i).childNodes(1).text & "<br/>" Response.Write pbrands.item(i).childNodes(2).text & ("<img src=""images/download_box.jpg"">") & "<br/>" Response.Write("<b>File Downloads</b>") & "<br/>" Response.Write "Link: " & pbrands.item(i).childNodes(3).text & "<br/>" Next %>
XSLCode:<?xml version="1.0" encoding="UTF-8"?> <?xml-stylesheet type="text/xsl" href="pb.xsl"?> <csvXml> <row> <aaa> <main_category>Main</main_category> <sub_category>Sub</sub_category> <spec_sheet>Product</spec_sheet> <sectionnumber><a href="pb.pdf">Spec</sectionnumber> </aaa> </row>
Code:<?xml version="1.0" encoding="UTF-8"?><!-- DWXMLSource="/PlumbingHVACDEV2010/pbtoc.xml" --> <!DOCTYPE xsl:stylesheet [ <!ENTITY nbsp " "> <!ENTITY copy "©"> <!ENTITY reg "®"> <!ENTITY trade "™"> <!ENTITY mdash "—"> <!ENTITY ldquo "“"> <!ENTITY rdquo "”"> <!ENTITY pound "£"> <!ENTITY yen "¥"> <!ENTITY euro "€"> ]> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output method="html" encoding="UTF-8" doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/> <xsl:template match="/"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <title>Untitled Document</title> </head> <html> <body style="color:#666; font-size:20px"> <table border="5"> <tr> </tr> <xsl:for-each select="csvXml/row"> <tr> <td><xsl:value-of select="spec_sheet"/></td> <td><xsl:value-of select="sectionnumber"/></td> </tr> </xsl:for-each> </table> </body> </html> </html> </xsl:template> </xsl:stylesheet>




that couldnt be the issue though? i'll change the // out to '


Bookmarks