Results 1 to 3 of 3

Thread: binding form's properties from popup window

  1. #1

    Default binding form's properties from popup window

    I have a main jsp page from which onSubmit, I need to open a popup window to get input from user. The user input I get, I need to bind them to the form properties. I tried using the spring bind tag, but it did not work. I am not sure what I need to do in the popup page to bind the value back to the form properties.

  2. #2
    Join Date
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,104

    Default

    Can you clarify? Is the popup part of the main form? If so, why not use hidden form inputs in the parent window. Open the popup before submitting, and use Javascript to set the parent form values - then submit.

  3. #3
    Join Date
    Dec 2004
    Location
    Bucuresti, Romania
    Posts
    72

    Default

    I think in this case you need to use some javascript. For example you have a form in the parent window:
    < form name="parentForm" >
    < input type="hidden" name="property1">
    < input type="hidden" name="property2">
    < / form >
    And you have the form on the popup window:
    < form name="popupForm" >
    < input type="text" name="property1">
    < input type="text" name="property2">
    < input type="button" value="Submit" onClick="doIt();" >
    < / form >
    When you submit the pop-up widonw a small javascript is called. This javascript function populates the form from the parent window and submits it.
    function doIt(){
    window.opener.parentForm.property1= popupForm.property1;
    window.opener.parentForm.property2= popupForm.property2;
    window.opener.parentForm.submit();
    }

Similar Threads

  1. FlowExecutionStorage in a DB
    By cacho in forum Web Flow
    Replies: 7
    Last Post: Oct 19th, 2009, 03:36 PM
  2. Replies: 3
    Last Post: Feb 8th, 2007, 03:33 PM
  3. Replies: 4
    Last Post: Jun 2nd, 2006, 09:56 AM
  4. Forms and nested properties
    By DaGGeRRz in forum Swing
    Replies: 0
    Last Post: Feb 23rd, 2005, 08:59 AM
  5. Replies: 2
    Last Post: Aug 17th, 2004, 04:16 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •