XML generated from JSP does not invoke XSLT according to W3C spec.

RESOLVED INVALID

Status

()

Core
XSLT
RESOLVED INVALID
13 years ago
13 years ago

People

(Reporter: C.George, Assigned: peterv)

Tracking

Trunk
x86
Windows 2000
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

13 years ago
Example which works:

Given a static XML file with URL "test.xml", and an XSLT file "test.xsl", with
correct XML/XSL headers, Firefox successfully and correctly performs an XSLT
translation on the XML file.

Example which doesn't work:

Given a dynamically-generated XML file with URL "test.jsp", with correct XML/XSL
headers (but no .xml extension), Firefox just loads the XML data and does not
perform an XSLT translation on the file.  IE6 does process this XML/XSLT
combination correctly.

Samples used for testing:

(file test.xsl)

<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<html>
<body>
This text appears (correctly) in IE6, but not in Firefox 1.0 PC
</body>
</html>
</xsl:template>
</xsl:stylesheet>

(file test.jsp ... not JSP specific...could use other system if desired)

<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="test.xsl"?>
<doc>
This text should not appear in either Firefox or IE6
</doc>

Other than that, I'm really happy with Firefox so far.  You've got a great
system here!

-- Chris
Worksforme, from PHP: with proper mime-types, testxml.php and testxsl.php, and
for bonus points test.abracadabra and test.kalamazoo, worked perfectly. To get
any traction, you'll probably need to put up a publicly available testcase, to
stop people from assuming that you didn't really get the types right.
Assignee: firefox → peterv
Component: General → XSLT
Product: Firefox → Core
QA Contact: firefox.general → keith
Version: 1.0 Branch → Trunk

Comment 2

13 years ago
make sure that both files are sent with text/xml or application/xml mimetypes.
And not text/xsl, there is no such mimetype. (We accept it as type in the 
stylesheet PI, though.)
JSP sends everything as text/html by default, so marking invalid.  Please reopen
if you're actually sending the right MIME type and seeing this.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 13 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.