This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Avoiding hard-coding the included XSL file name


Thanks for the information.

That was what I was afraid of.

Your idea of a /import seems to be the easiest.
It just another step in the installation procedure.

Sia.


>From: "Evan Lenz" <elenz@xyzfind.com>
>Reply-To: xsl-list@mulberrytech.com
>To: <xsl-list@mulberrytech.com>
>Subject: RE: Avoiding hard-coding the included XSL file name
>Date: Fri, 25 Aug 2000 13:33:16 -0700
>
>Kay, pg. 120:
>
>"Attribute value templates are never allowed for attributes of top-level
>elements.  This ensures that the values are known before the source 
>document
>is read, and are constant for each run of the stylesheet."
>
>Thus you cannot, say, pass the href attribute value in as a parameter,
>because run-time assignment of that value is not allowed.
>
>My suggestion is to use something outside of XSLT like symbolic links so
>that the included file will be accessible via the same relative path
>location for either stylesheet.  We use a number of imported stylesheets in
>our software.  We solve the problem of multiple file locations by
>symbolically linking to the import/ directory where we keep our imported
>stylesheets.
>
>Hope this helps.
>
>Evan Lenz
>elenz@xyzfind.com
>http://www.xyzfind.com
>XYZFind Corp. "Building Better Search"
>
>
>-----Original Message-----
>From: owner-xsl-list@mulberrytech.com
>[mailto:owner-xsl-list@mulberrytech.com]On Behalf Of Sia Rahimi
>Sent: Friday, August 25, 2000 11:38 AM
>To: xsl-list@mulberrytech.com
>Subject: Avoiding hard-coding the included XSL file name
>
>
>I use a Unix/Apache/JServ/Servlet/Xalan environment.
>I have a common-attributes.xsl file which I include in all my xsl files.
>
>The problem is that to get that file to be found I need to hard code the
>file name as such:
><xsl:include href="http://sia1.sia.net/html/xsl/common_attributes.xsl"/>
>or
><xsl:include href="/users/sia/html/xsl/common_attributes.xsl"/>
>
>relative path to the xsl file or the servlet doesn't seem to work.
>
>Does anybody know of a way to avoid this hard-coding?
>
>Thanks for any help you may be able to provide.
>
>Sia.
>________________________________________________________________________
>Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com
>
>
>  XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
>
>
>  XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]