[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: using a parameter to modify part of the file path
Thanks.
However, I can not quite get it to work. I must be doing something wrong. I have this in my transformer set-up: transformer.setParameter("buildingDataFile", this.buildingDataName); where this.buidingDataName is "TownHouseData" Then, in my style sheet I have, as you suggested, <xsl:variable name="list" select="document(concat('../', $buildingDataFile, '/inputXML/storyPages.xml'))"/> However, I get this error message, stating that the variable, $buildingDataFile has not been declared. Error at xsl:variable on line 15 of file:///C:/Documents%20and%20Settings/Tracey/workspace/LibraryProject/xslt/stories.xsl: XPST0008: XPath syntax error at char 40 on line 15 in {...le, '/inputXML/storyPages.x...}: Variable $buildingDataFile has not been declared In other cases, I have been able to make use of transformer parameters into the html part of astylesheet with something like this: <li><a href="../index.html" title="{$buildingTitle}"> , where buildingTitle was a transformer parameter, but, as I said before, whenever I try to get a parameter into a quoted function, I get into trouble. What am I missing? There is a more going on in the stylesheet, but nothing really before this line, so I haven't included it. ----- Original Message ----- From: "Michael Kay" <mike@xxxxxxxxxxxx> To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx> Sent: Sunday, September 17, 2006 3:23 AM Subject: RE: using a parameter to modify part of the file path in document(...) function Change your call on document() to
|
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
|