RE: [xsl] Re: Flat -> Hierarchy --- Continue

Subject: RE: [xsl] Re: Flat -> Hierarchy --- Continue
From: "Passin, Tom" <tpassin@xxxxxxxxxxxx>
Date: Thu, 29 May 2003 15:28:50 -0400
[ Dongling Ding]
> My xslt is a generic script. It doesn't know the xml
> file name. Is there any other way to do the same
> thing?

There are several ways, and it depends on how you want to invoke the
transformation.  The simplest thing to do is to pass in the file name as
a parameter to the stylesheet.  You can do this on the command line, or
programatically if you invoke the processor that way.  How you do it
varies from one processor to the other.

Another way is to use a driver file - an xml file, of course - which
specifies both the data file and the hierarchy structure specification.
Then you use document() to bring in each of them, after getting their
names from the driver file.  The driver file would be the file that you
present to the stylesheet for processing.  If you will be doing a lot of
these tasks but changing the source and structure for each run, a driver
file would be best because it would be easy to maintain and to change.

There are other possibilities but these are probably the best


Tom P

 XSL-List info and archive:

Current Thread