ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> perl-xml
perl-xml
XSLT question (passing parameters)
by David Craig other posts by this author
Nov 19 2005 4:44AM messages near this date
view in the new Beta List Site
Re: Repeated RSS elements | Re: XSLT question (passing parameters)
& XSLT Hello all,

I'm having a problem with passing in external parameters... I've tried 
several transformation engines (komodo built in, XML::LibXSLT) to no 
avail, so I think I'm making a mistake in the code. A really simple 
example is this:

<?xml version="1.0" encoding="UTF-8"?> 
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
version="1.0"> 
<xsl:param name="x"/> 

<xsl:template match="/"> 
            <xsl:text> |</xsl:text><xsl:value-of select="$x" 
/> <xsl:text>|</xsl:text>
    </xsl:template> 
</xsl:stylesheet> 

I would expect to get "|valueofx|" but instead I get "||"

Am I being stupid?

Thanks for your help!

--David Craig

_______________________________________________
Perl-XML mailing list
Perl-XML@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
David Craig
Lars Haugseth
A. Pagaltzis
Stephane Roux
A. Pagaltzis

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved