[Javascript] Submitting form in a parent window

Mark Christie MChristie at avsgroup.com
Thu May 10 09:14:41 CDT 2001


Thanx for the response...But we found the answer over here...

The Submit button in the parent window was named "submit"...so form.submit
ended up referring to the button itself...

Regards,
   -Mark C.



-----Original Message-----
From: Peter Brunone [mailto:peter at brunone.com]
Sent: Wednesday, May 09, 2001 4:11 PM
To: javascript at LaTech.edu
Subject: Re: [Javascript] Submitting form in a parent window


    Why do you have a parameter in the submit method?  The proper syntax for
form submission is

document.formname.submit();

    Also, any particular reason why you're showing us the ASP that builds
your script rather than the script itself?  That might be more helpful...

-Peter

----- Original Message -----
From: "Mark Christie" <MChristie at avsgroup.com>
To: <javascript at LaTech.edu>
Sent: Wednesday, May 09, 2001 3:47 PM
Subject: [Javascript] Submitting form in a parent window


> Hello, list.
>
> Here's my code:
>
> Sub SubmitParent()
> Response.Write "<Script Language=""JavaScript"">" & VbCrLf
> Response.Write "var frm =
> window.parent.opener.document.forms.frmManage;" & VbCrLf
> Response.Write "frm.CommentFlag.value=1;" & VbCrLf
> Response.Write "frm.submit(frm.name);" & VbCrLf
> Response.Write "</Script>" & VbCrLf
> End Sub
>
> The error I get is:
>
> Line: 3
> Error: Object doesn't support this property or method
>
> I've tried every permutation I can think of...I can get at the values of
the
> form, CommentFlag, frm.name, everything comes back...but can't submit the
> thing...!
>
> Any ideas out there?
>
> Regards,
>    -Mark C.
>
>
>
>
> _______________________________________________
> Javascript mailing list
> Javascript at LaTech.edu
> http://www.LaTech.edu/mailman/listinfo/javascript
>


_______________________________________________
Javascript mailing list
Javascript at LaTech.edu
http://www.LaTech.edu/mailman/listinfo/javascript




More information about the Javascript mailing list