This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes XML and Related Technologies and the fly likes How can I pass a value from javascript in a jsp to XSL Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "How can I pass a value from javascript in a jsp to XSL" Watch "How can I pass a value from javascript in a jsp to XSL" New topic
Author

How can I pass a value from javascript in a jsp to XSL

Rianth Thomas
Greenhorn

Joined: Apr 21, 2004
Posts: 1
HI,
Please help.I need to know how I can pass a valuefrom javascript in a jsp to a xsl called a.xsl.
My problem is I have the value of select's options as a value in the javascript and I want to pass that whole value for example I have the value in the javascript as given below in a variable.
<option value="url1">option1</option>
<option value="url2">option2</option>
<option value="url3">option3</option>
<option value="url4">option4</option>
I want to pass the whole value to the a.xsl's select, option as below , I have no options now for the select in the xsl.
<select id="id1">
<option value="url1">option1</option>
</select>
thanks in Advance,
Please help.
Rianth.
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
Is your problem that you don't know how to pass the user's selection from the browser to the server, or that you don't know how to pass parameters to an XSL stylesheet? If it's the latter, then this might help. If it's the former, that's really a JavaScript question and should be asked in the HTML/JavaScript forum.


Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: How can I pass a value from javascript in a jsp to XSL