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

RE: Cant see params passed to the xsl sheet

Subject: RE: Cant see params passed to the xsl sheet
From: "Avula, Raj" <RAvula@xxxxxxxxxxx>
Date: Wed, 5 Jun 2002 18:12:18 -0700
transformer.setparam
	
Check whether you are enclosing the parameter in single quots (
'param_value' ) 
instead of ( param_value ).

In your style sheet also you should  have
<xsl:param name="tablename" select="'none'"/>
rather than
<xsl:param name="tablename" select="none"/>

if you don't have quots, processor tries to resolve it as xpath expression.

Thanks,
Raj..


-----Original Message-----
From: Lloyd, Colin [mailto:clloyd@xxxxxxxxxxxx]
Sent: Wednesday, June 05, 2002 5:58 PM
To: 'XSL-List@xxxxxxxxxxxxxxxxxxxxxx'
Subject:  Cant see params passed to the xsl sheet


I'm using the Xalan 2.3.1 processor and can't see the parameters I've passed
to it using when using <xml:param>and <xml:value-of>.  Anyone ever had a
similar problem? I've tried passing parameters programatically with
Transformer.setParam() and running org.apache.xalan.xslt.Process from the
command line and passing them in there with the -PARAM option.  Niether
seems to work so I suspect my stylesheet is incorrect.  Here it is:

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

<xsl:param name="tablename" select="none"/>
<xsl:param name="package" select="none"/>

<xsl:output method = "text"/>

<!-- Collect parameters that have been passed to us -->
<xsl:template match="app-data">
    <!-- Dump the settings for this stylesheet -->
    in app-data
    my table name is: <value-of select="$tablename"/>
    <xsl:apply-templates select="database"/>
</xsl:template>

<xsl:template match="database">
    in database
    my table name is: <value-of select="$tablename"/>
</xsl:template>
</xsl:stylesheet>


Thanks in advance.




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


"MMS <firstam.com>" made the following
 annotations on 06/05/02 18:14:09
------------------------------------------------------------------------------
"THIS E-MAIL MESSAGE AND ANY FILES TRANSMITTED HEREWITH, ARE INTENDED SOLELY FOR THE USE OF THE INDIVIDUAL(S) ADDRESSED AND MAY CONTAIN CONFIDENTIAL, PROPRIETARY OR PRIVILEGED INFORMATION.  IF YOU ARE NOT THE ADDRESSEE INDICATED IN THIS MESSAGE (OR RESPONSIBLE FOR DELIVERY OF THIS MESSAGE TO SUCH PERSON) YOU MAY NOT REVIEW, USE, DISCLOSE OR DISTRIBUTE THIS MESSAGE OR ANY FILES TRANSMITTED HEREWITH.  IF YOU RECEIVE THIS MESSAGE IN ERROR, PLEASE CONTACT THE SENDER BY REPLY E-MAIL AND DELETE THIS MESSAGE AND ALL COPIES OF IT FROM YOUR SYSTEM."

==============================================================================


 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.