You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Anders Högqvist <ho...@hotmail.com> on 2001/04/17 10:07:04 UTC
Problems with different stylesheets
Hi!
I'm trying to apply two different stylesheets to an XML-file, one for wap and one for Netscape and Explorer. The xml-file looks like this:
<?xml-stylesheet type="text/xsl" href="style/wap.xsl" media="wap"?>
<?xml-stylesheet type="text/xsl" href="style/html.xsl" media="mozilla5"?>
<?xml-stylesheet type="text/xsl" href="style/html.xsl" media="explorer"?>
When I try to access the site in Netscape and from a wap-phone it's working, but from explorer 5 I get this message:
*******************************
The XML page cannot be displayed
Cannot view XML input using style sheet. Please correct the error and then click the Refresh button, or try again later.
--------------------------------------------------------------------------------
The character '>' was expected. Line 81, Position 5
-- media type, as per [RFC2045]
----^
*******************************
If I copy the produced HTML code and save it to a html file I can open it in explorer and view it without problems. What am I doing wrong here? The XML file doesn't have 81 lines and in the XSL file there is no missin >-character.
/Anders Högqvist
Re: Problems with different stylesheets
Posted by Frans Thamura <ft...@yahoo.com>.
Never happen with my script.
Usually the error in netscape, not in internet
explorer???
Frans
--- Anders_H�gqvist <ho...@hotmail.com> wrote:
> Hi!
>
> I'm trying to apply two different stylesheets to an
> XML-file, one for wap and one for Netscape and
> Explorer. The xml-file looks like this:
>
> <?xml-stylesheet type="text/xsl"
> href="style/wap.xsl" media="wap"?>
> <?xml-stylesheet type="text/xsl"
> href="style/html.xsl" media="mozilla5"?>
> <?xml-stylesheet type="text/xsl"
> href="style/html.xsl" media="explorer"?>
>
> When I try to access the site in Netscape and from a
> wap-phone it's working, but from explorer 5 I get
> this message:
>
> *******************************
>
> The XML page cannot be displayed
> Cannot view XML input using style sheet. Please
> correct the error and then click the Refresh button,
> or try again later.
>
>
>
--------------------------------------------------------------------------------
>
> The character '>' was expected. Line 81, Position 5
>
> -- media type, as per [RFC2045]
> ----^
> *******************************
> If I copy the produced HTML code and save it to a
> html file I can open it in explorer and view it
> without problems. What am I doing wrong here? The
> XML file doesn't have 81 lines and in the XSL file
> there is no missin >-character.
>
> /Anders H�gqvist
>
>
__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/
---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>