RobBroekhuis
Technical User
I have a "preview" window (opened by my main window), on which there is a button to "submit" the information. The form to submit is on my main window. I thought the following should work:
<form onSubmit="window.close()">
<input type="submit" value="close and edit">
<input type="submit" value="submit" onClick="opener.document.forms['SubmitThread'].submit()">
</form>
But it doesn't. Both buttons merely close the preview window. The form is properly addressed (I can alert the value of a field on the form just fine), but the submit method doesn't trigger. If it matters - the form has an onSubmit clause that triggers a Javascript form validation routine.
What am I doing wrong?
Rob
![[flowerface] [flowerface] [flowerface]](/data/assets/smilies/flowerface.gif)
<form onSubmit="window.close()">
<input type="submit" value="close and edit">
<input type="submit" value="submit" onClick="opener.document.forms['SubmitThread'].submit()">
</form>
But it doesn't. Both buttons merely close the preview window. The form is properly addressed (I can alert the value of a field on the form just fine), but the submit method doesn't trigger. If it matters - the form has an onSubmit clause that triggers a Javascript form validation routine.
What am I doing wrong?
Rob
![[flowerface] [flowerface] [flowerface]](/data/assets/smilies/flowerface.gif)