Loading an external file of index
I have a lot fo files that are using a shared common index for managing references. Something like :
1) lot of files with contents like :
<xmlfile><p>Here I want to define the <keyref linkend="xml"/> standard</p></xmlfile>
2) an other file called shared.xml with :
<key name="xml"><acronym>xml</acronym><title>eXtended Markup Language</title></key>
<key name="xsl"><acronym>xsl</acronym><title>eXtended Style Sheet Language</title></key>
What I want to do is, while formatting my xml files to HTML, is to load first the shared.xml file for getting as a set of keys in order to be able to use it for formatting all files.
In XSL T, it is something like :
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:output method="html" indent="no"/>
My problem is that the standard says that the <xsl:key> declaration needs to be at the top root node level of a stylesheet and that at this time, the key elements coming from the imported file are unknown.
So, the question is where do I declare <xsl:key name="mysetofkeys" match="key" use="@name"/> for being able to fill the table with all keys from the imported file ?
PS : By the way, an other subconsequent question is how is it possible, for debugging purpose, to output the content of a key table ? Something like print(key("mysetofkeys')) ... ?
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format