[thelist] Empty Form Responses --> Re: How do I clear form inputfields onSubmit (or somehow)?

Simon sentient at mm0.net
Thu Aug 3 14:28:30 CDT 2000


At 10:41 AM -0700 8/3/00, Anthony Baratta wrote:
>  In order for data to be submitted the page must talk to the script.
>  (e.g. 'post' data to the CGI program) This basically 'loads' the cgi
>  script, which must either redirect to another page (e.g. thank you)
>  or throw HTML at the browser.
>
>  What you should do is use your 'reset script' so that when the page
>  loads, the form is blanked. Then have your CGI script redirect back
>  to the form page after accepting the data.
--


Actually we don't have any 'reset script' at all, just a simple perl 
form mailer. Since submitting the comment card form opens a little 
confirmation popup window what I think I need is something that sends 
the form "reset" command back to the original page when the 
confirmation popup loads. I'm just not sure how to construct the JS 
code for it. What I think I need in the little popup window is 
something like this...

    <body onLoad="window.opener.form.commentcard.reset()">

Is that even close to the syntax construction for sending a reset 
back to the form on a page (still open in the background) that opened 
the new window?

Simon
-- 

------------------------------------------------
Sentient Technologies - mailto:sentient at mail.com
------------------------------------------------





More information about the thelist mailing list