| Author |
Two dropdowns - need to indicate to server side code the specific dropdown
|
pendse anagha
Ranch Hand
Joined: Mar 09, 2005
Posts: 44
|
|
Hello , I have two dropdowns in my JSP page The problem is - I need to pass an indicator as to which dropdown has been changed Both the dropdowns are in the same form I would like to know - if its possible to pass an indicator through Javascript that can be picked up in Java code Thanks in advance , anagha [ May 16, 2005: Message edited by: pendse anagha ]
|
 |
William Brogden
Author and all-around good cowpoke
Rancher
Joined: Mar 22, 2000
Posts: 12268
|
|
You are mixing up a lot of technologies here. In an HTML form, each SELECT input should have a unique name so you could simply compare the returned value with the value originally set as SELECTED. Whether the HTML gets written by JSP or is a static page has nothing to do with it. If you want JavaScript to watch form activities and make some report, you can do that with one or more hidden variables in the form. Hidden variables in forms appear as request parameters just like SELECT input variable. Bill
|
Java Resources at www.wbrogden.com
|
 |
Ben Souther
Sheriff
Joined: Dec 11, 2004
Posts: 13410
|
|
This question would probably do better in the HTML/Javascript forum but here's one way: You'll probably need to tweak it a bit to get it to work on older browsers. [ May 16, 2005: Message edited by: Ben Souther ]
|
Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
|
 |
 |
|
|
subject: Two dropdowns - need to indicate to server side code the specific dropdown
|
|
|