Click to See Complete Forum and Search --> : submit form using 2 open windows


ronnie99
03-11-2003, 07:43 PM
hi there,

let's say i have the main submission form in one window and another pop-up window with some buttons (such as "continue upload","stop upload",etc.).
how do i pass the true/false submission values to the original form???


10x, r. :)

requestcode
03-12-2003, 11:34 AM
You can reference variables, functions and form elements in the original window that opened the popup by using the "opener" property. For example if you wanted to perform a function in the "opener" window you would do this:
opener.function_name(somevalue)

If you wanted to populate a variable in the "opener" window then you would do this:
opener.variable_name="some value"

A form element:
opener.document.form_name.field_name.value="some value"

You should also be able to submit the form this way:
opener.document.form_name.submit()

Not sure if this answers your question directly, but is is one way of accessing your original window.