failing to get reference to form object in Firefox

L

laredotornado

Hi,

I must be losing my mind -- I've forgotten how to get a reference to a
form! If you look at this page ...

http://www.dhlovelife.com/v2/knowdummy/magcommunity_post.php

I'm trying to submit the form after validating it. But, on PC
Firefox, I repeatedly get the error "f.submit is not a function" when
I try and submit the form using "f.submit()" where f is passed in from
the submit button, like so

<input type="button" value="Submit" name="submit"
onClick="validateForm(this.form);" />

Grateful for your help, - Dave
 
P

Paul Lautman

laredotornado said:
Hi,

I must be losing my mind -- I've forgotten how to get a reference to a
form! If you look at this page ...

http://www.dhlovelife.com/v2/knowdummy/magcommunity_post.php

I'm trying to submit the form after validating it. But, on PC
Firefox, I repeatedly get the error "f.submit is not a function" when
I try and submit the form using "f.submit()" where f is passed in from
the submit button, like so

<input type="button" value="Submit" name="submit"
onClick="validateForm(this.form);" />

Grateful for your help, - Dave

Did you not think of searching Google for
javascript form validate

obviously not. Use an onsubmit handler in the form tag.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,020
Latest member
GenesisGai

Latest Threads

Top