xsl-list
[Top] [All Lists]

RE: Dynamic path in xsl:import

2005-09-12 00:58:02
Using the term "dynamic" is perhaps unfortunate, as it suggests you want to
do the import at run-time, which isn't possible. But I don't think that's
what you need here.

First, try to do it with relative URIs. So long as all the stylesheet
modules have the same relative locations in the two directory structures
this should work fine.

If there's some reason relative URIs won't do the job (I can't think of one
off-hand), you can write your own URIResolver that takes the URI specified
in the href attribute and returns a JAXP Source object containing the
stylesheet module. That gives you complete flexibility.

Michael Kay
http://www.saxonica.com/

-----Original Message-----
From: SINGH Navpreet [mailto:Navpreet(_dot_)SINGH(_at_)Tenix(_dot_)com] 
Sent: 12 September 2005 00:33
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] Dynamic path in xsl:import

Hi,
Developing an application that uses number of xslt files to 
transform XML. Main XSLT file has many xsl:import statements. 
Application needs to be deployed on the tomcat server. Tomcat 
could be on installed on separate location on two different 
machines. How can I give a dynamic path for child xslt files 
in the xsl:import statements depending upon server location?
Thanks,
Navpreet. 



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--





--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>