Subject: RE: importing/including a stylesheet
From: "Robert Koberg" <rob@xxxxxxxxxx>
Date: Wed, 4 Jun 2003 13:29:08 -0700
|
> -----Original Message-----
> From: florian [mailto:csshsh@xxxxxxxxxxxxxxx]
> Sent: Wednesday, June 04, 2003 1:03 PM
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Cc: Robert Koberg
>
> >>>
> >>> By default it will be relative to the file rather than the directory.
> >>> Does
> >>> that help?
> >>
> >> it would... but when i deploy the app in jboss its always relativ to
> >> my
> >> jboss directory..
> >
> > Then there is a bug in your XSL processor (or possibly jboss?). What
> > XSL
> > processor are you using?
>
> im using the processor which comes with java 1.4.1.. (the apple
> implementation)
Ahhh.. apple... I have been using my dual processor g4 to listen to iTunes
mostly...
You could also try using saxon as your processor. But I really don't know
who owns this bug.
>
> > If you are using Resin and it's processor, there is a known bug that
> > should
> > be fixed in the latest snapshot release (haven't had a chance yet to
> > try
> > it).
> >
> > You could also try to use a custom URIResolver setting the resolution
> > explicitly.
>
> how could i do that?
For xsl:import/include use the setURIresolver method of the
TransformerFactory. For document() use the same method on the Transformer.
An example resolver might look like:
class MyURIResolver implements URIResolver {
private MyProject project;
public GeneratingURIResolver(MyProject _project) {
this.project = _project;
}
public Source resolve(String href,String base) {
if (href.endsWith(".xsl")) {
return new StreamSource(something);
} else {
return new StreamSource(something else);
}
}
}
Best,
-Rob
>
> thanks alot in advance!
>
> ciao!
> florian
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|