Re: [xsl] Set XSL-Value in a JavaScript

Subject: Re: [xsl] Set XSL-Value in a JavaScript
From: Martin Honnen <Martin.Honnen@xxxxxx>
Date: Tue, 30 Sep 2008 14:13:46 +0200
henry human wrote:

If you wanted to get the value of /details/address,
you'd have to write:

OnSendForm( {/details/address} )
I think you did not consider that i will to read in
the XSL an email address from a XML file and put it as
parameter in the JavaScript.!

He did consider that and suggests to use an attribute value template for that where you put an XPath expresssion (e.g. /details/address) into curly braces. The only thing missing are single quotes around the value to make JavaScript happy:
<input type="submit" onclick="OnSendForm('{/details/address}');" value="Send!"/>
You can read about attribute value templates here:


	Martin Honnen

Current Thread