[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

passing NodeList through Global Paramter to XSL styles

Subject: passing NodeList through Global Paramter to XSL stylesheet problem
From: "Fernandes, John" <jfernandes@xxxxxxxxxx>
Date: Tue, 29 Apr 2003 14:19:39 -0400
download org.apache.crimson.tree.xmldocument
Here are pieces of the code.

<?xml version="1.0"?> 
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xalan="http://xml.apache.org/xalan"
exclude-result-prefixes="xalan">


***This Global Parameter is a NodeList generated in Java Servlet and Passed
to XSL stylesheet but it seems to be coming as a tree fragment

<xsl:param name="employer"/>

<xsl:template match="test"> 


***Convert TreeFragment into a NodeList using Xalan

<xsl:variable name='v_employer' select="xalan:nodeset($employer)"/>

***** This is just for viewing the object that is being passed
<xsl:copy-of select="$v_employer"/>
(org.apache.crimson.tree.XmlDocument@1f7708)-on screen

just so you know in the nodelist we have a root element called <employer>
with child elements called <option> and in each option some values.
<employer>
<option>1</option>
<option>2</option>
<option>3</option>
</employer> 

**** Attempt to produce a drop down list in XSL of the values from those
child elements.

<xsl:for-each select="$v_employer/option">
<xsl:value-of select="."/>
</xsl:for-each>

**** Nothing is showing up.

What is wrong how can I produce a drop down list and access those node
values.This is very urgent so any help would be appreciated. 


John M. Fernandes 


End


 

Get to know us
http://www.thestar.com - Canada's largest daily newspaper online
http://www.toronto.com - All you need to know about T.O.
http://www.workopolis.com - Canada's biggest job site
http://www.torontostartv.com - Webcasting & Production
http://www.newinhomes.com - Ontario's Largest New Home & Condo Website
http://www.waymoresports.com - Canada's most comprehensive sports site
http://www.tmgtv.ca - Torstar Media Group Television

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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.