Subject:Using XSLT to create XML output - how do I put in xml tag? Author:Kenneth Lee Date:12 Oct 2004 01:18 AM Originally Posted: 12 Oct 2004 12:15 AM
I don't have an offline driver so I'm using Netscape 7.2 to do my translating.
I used
<xsl:output method='xml' version="1.0" indent='yes'
standalone='yes' omit-xml-declaration='no' />
to try to create an xml header when none of my tags were showing up on screen.
Saving the page shows the tags, but has no change because of the above command.
Tried various other things without success.
When I tried Microsoft Internet Explorer, it redirected to a new window in Netscape.
<!--
<xsl:variable name='startXml' select='<?xml version="1.0"?>'/>
<![CDATA[<?xml version="1.0"?>]]>
-->
I think the ? terminates both of these with an invalid character, but doesn't show what it really is complaining about.
Removing the ? does remove the error message, but doesn't make the file xml.
I later found this:
<xsl:processing-instruction name='xml'>version="1.0"</xsl:processing-instruction>
If I save and open the page, I get normal XML browser output, but the direct xml conversion still strips and hides all tags from the view.
I'd like to see the converted xml output file without first saving it.
Interesting little edit feature. You enter text with linefeeds originally, it enters <br> commands.
then you edit it, it retains the linefeeds and shows <br> in the text. When you re-post, <br> becomes part of the
text and all linefeeds go away.
Subject:Using XSLT to create XML output - how do I put in xml tag? Author:Tony Lavinio Date:12 Oct 2004 10:51 AM
It's not clear exactly what you are doing. Are you running the transform
in Stylus, saving the output, and then trying to view it in IE and/or
Netscape? Are you using a webserver, or just looking at files in the
filesystem? Are you depending on IE's XSLT engine, or Netscape's? Did
you use an .xml document with an xsl-stylesheet PI, as specified in http://www.w3.org/TR/xml-stylesheet/ ?
Subject:Using XSLT to create XML output - how do I put in xml tag? Author:Kenneth Lee Date:12 Oct 2004 05:13 PM
I have a file on my PC with an .xml extension, it links to a file with an .xsl extension.
I double click the .xml file from Windows Explorer, it brings up Netscape which shows just a string of text.
If I copy the file:: link, manually bring up Internet Explorer, copy the link and hit enter, it brings up a new Netscape window which shows just a string of text.
If I copy the Netscape page to another .xml file and double click that file, I get a well formed XML document output listing instead of a string of text.
Originally I asked how to put in the <?...?> processing command. More reading answered that question. Now I'm wondering why I'm not getting XML output when I'm sending XML input and if there is a cure for that.
Subject:Using XSLT to create XML output - how do I put in xml tag? Author:Kenneth Lee Date:12 Oct 2004 05:19 PM Originally Posted: 12 Oct 2004 05:16 PM
Whoops, meant "...bring up Internet Explorer, paste the link and hit enter..."<br>
Considering what edit did to me the first time, this time I'll just add a reply instead.
Subject:Using XSLT to create XML output - how do I put in xml tag? Author:Kenneth Lee Date:13 Oct 2004 01:17 AM
I don't mind going to Netscape as my default as long as it works properly.
Note that something in my configuration has disabled IE from rendering XML files. Probably happened when I downloaded Netscape 7.2. I don't know if rendering problem exists there as well
Here are my files:
Subject:Using XSLT to create XML output - how do I put in xml tag? Author:Ivan Pedruzzi Date:13 Oct 2004 03:50 PM
kenneth,
The problem is that Netscape renders the xml document (the result of the transformation) as it was HTML.
What you see are the tag values; tags that are not HTML are ignored.
Netscape doesn't have a default stylesheet like IE does to display xml documents as HTML
If you type in IE res://msxml/defaultss.xsl you can see the transformation (written in the old xsl standard)
You don't need to create manually the xml pi, XSLT does it for you.
Subject:Using XSLT to create XML output - how do I put in xml tag? Author:Kenneth Lee Date:13 Oct 2004 08:40 PM
If I display FormExampleoUT.xml on Netscape, it gives me a warning message that it doesn't have a xslt document assigned and then displays the XML in a format that looks just like I remember IE doing with tags, colapsable(sp?) links, etc.
Subject:Using XSLT to create XML output - how do I put in xml tag? Author:Ivan Pedruzzi Date:14 Oct 2004 12:03 AM
Kenneth
Let me more precise, Netscape is able to render xml documents when loaded from URL
but seems to use a different execution path with the xslt transformation result.