GeeCON Prague 2014*
The moose likes HTML, CSS and JavaScript and the fly likes get parameter from another Form Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "get parameter from another Form" Watch "get parameter from another Form" New topic
Author

get parameter from another Form

Barry Andrews
Ranch Hand

Joined: Sep 05, 2000
Posts: 523

Hi,
Can anyone tell me if it is possible to get a parameter from another Form (on the same HTML page) and submit the values along with the Form that is being submitted? For example, I have a text field in Form 1 (same page) and I want to be able to get the value of the field and submit that along with data from Form 2. There should be a way to do this task with JavaScript. If someone could kindly point the way?
Many thanks,
Barry
Shubhrajit Chatterjee
Ranch Hand

Joined: Aug 23, 2001
Posts: 356
In form one, have a hidden field say ... hid1
then do this from javascript
document.form1.hid1.value = dcoument.form2.someinputfield.value


Shubhrajit
Barry Andrews
Ranch Hand

Joined: Sep 05, 2000
Posts: 523

Brilliant! Thanks a lot!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: get parameter from another Form