470,638 Members | 1,582 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,638 developers. It's quick & easy.

XSLT import relative path problem on Apache Tomcat

Using Apache Tomcat 5.0.28 I'm having a problem with the xsl:import
command.

I have several Tomcat running on the same server (they could be
different releases of code so can't share resources).

An XSLT script is called via a JSP to convert XML to HTML (<xsl:apply
nameXml="routesummary" xsl="/xsl/routesummaryheader.xsl" />).

This routesummaryheader.xsl script then needs to call another XSLT
script routesummarycontent.xsl and it does this via an import, for
example,

<xsl:import
href="http://localhost:8080/aaem/xsl/routesummarycontent.xsl" />

Now this works fine.

But I run many Tomcat servers on this box and so a specific URI is no
good. So I want to replace that import with a relative URI

<xsl:import href="routesummarycontent.xsl" />

This does not work, I get "Had IO Exception with stylesheet file:
routesummarycontent.xsl".

Note routesummaryheader.xsl and routesummarycontent.xsl are in the same
directory.

I've tried all kinds of relative paths in the import nothnig seems to
work.

The JSP file is under webapps\app-dir\jsp. The XSLT files are under
webapps\app-dir\xsl.
How do I fix this?

Apr 21 '06 #1
1 3999


ge*****************@yahoo.co.uk wrote:

The JSP file is under webapps\app-dir\jsp. The XSLT files are under
webapps\app-dir\xsl.
How do I fix this?


Have you tried
<xsl:import href="../xsl/routesummarycontent.xsl" />
?

But the problem is not so much with XML or XSLT but rather with that
JSP/Tomcat setup, not sure anyone here has experience with that.

--

Martin Honnen
http://JavaScript.FAQTs.com/
Apr 21 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Johannes Lebek | last post: by
2 posts views Thread by Jon Martin Solaas | last post: by
7 posts views Thread by Harolds | last post: by
4 posts views Thread by WStoreyII | last post: by
7 posts views Thread by Ron Adam | last post: by
???
1 post views Thread by Stoney L | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.