Re: Local copy of XSLT style sheet doesn't work

Troy,

I don't think that IE yet recognizes the "application/xhtml+xml" MIME type.

It therefore apparently treats a ".xhtml" file as exotic, and tries to 
download it rather than open it (i.e., it treats it as a file of a type it 
doesn't recognize, such as ".glotz"). If you tell it to open the file 
rather than save it, it will try to do so ... but will still first save it 
to your Temporary Internet Files folder (IE's local cache), and then try to 
open it from there; effectively, it is then opening a locally-stored copy 
of the file. Having done this, IE also seems to use the Temporary Internet 
Files folder as the base from which to resolve the relative reference to 
the mathml.xsl file, which isn't helpful because, of course, the mathml.xsl 
file is located on the server. (It may also be stored locally, of course, 
but the relative reference from the Temporary Internet Files folder is not 
going to get you there.)

If I download your test file and then copy it to a local folder that places 
it correctly in the tree hierarchy relative to the location of my own local 
copy of mathml.xsl, then the file opens correctly.

Assuming that your web server is also configured to provide the correct 
MIME type for ".xsl" and ".xml" files (many servers still aren't; check 
with your IT people), try changing your filetype from ".xhtml" to ".xml" to 
see if that works. There are probably more elegant workarounds for this 
peculiarity of IE; if so, I hope someone from the group will suggest them.

--MB




At 02:57 2003/12/29, you wrote:
>I followed the recommendations for "putting mathematics on the web using 
>MathML", but I can't get the XSLT style sheets to work with Internet 
>Explorer version 6.0 service pack1. I copied all four of the style sheets 
>to my web server and put a small test page with embedded MathML in the 
>same folder as the style sheets. The xml stylesheet instruction refers to 
>mathml.xsl in the correct folder, but when I try to view my test page, 
>Internet Explorer appears to download mathml.xsl and try to execute it 
>locally. I get an error message that indicates the file could not be found 
>in my temporary internet files folder. Any idea what's wrong?
>
>Here's a link to the file I'm talking about:
>
><http://www.scriptedmotion.com/mathMLStyles/crossBrowserExample.xhtml>http://www.scriptedmotion.com/mathMLStyles/crossBrowserExample.xhtml
>
>The xslt style sheets are in the same folder as the 
>"crossBrowserExample.xhtml" file. The page displays properly in Netscape 
>7.1, just not in Internet Explorer.
>
>Here's the error message I get:
>
>
>The XML page cannot be displayed
>
>Cannot view XML input using XSL style sheet. Please correct the error and 
>then click the <javascript:location.reload()>Refresh button, or try again 
>later.
>
>----------
>The system cannot locate the resource specified. Error processing resource 
>'file:///D:/Documents and Settings/Administrator/Local Settings/Temporary 
>Internet Files/Content.IE5/8D6N0HQB/mathml.xsl'.
>
>Thanks for your help,
>
>Troy Martin

Received on Monday, 29 December 2003 17:38:36 UTC