spikesource hints'n'tips

Our Top Tags

                                       

Mailing List

Keep uptodate with the latest hints'n' tips as they are published by signing up to our mailing list.

Our RSS Feeds








Latest Linux News

20 Beautiful Dark Themes for Gnome and Ubuntu

Tuesday, 19 August 2008
Cats Who Code: "Some weeks ago, I shown you a list of 30 themes for enhancing your Gnome desktop."

OpenSolaris: a Linux Admin's View

Tuesday, 19 August 2008
Linux Format: "Sun is battling hard to break into the open source operating system world with OpenSolaris. Juliet Kemp takes it for a test-drive, sampling its unique features and seeing how it fares a

What's That They Say About Assumptions?

Tuesday, 19 August 2008
Blog of Helios: "Sometimes Linux isn't the answer."

The Brampton Factor: Analysts Fail on Open Source

Tuesday, 19 August 2008
IT Pro: "For open source software to achieve its full potential, people's perceptions must change. Yet how can that happen when open source is so woefully neglected by analysts, asks Martin Brampton."

Why Red Hat Invested In JBoss Instead Of Linux Desktops

Tuesday, 19 August 2008
The VAR Guy: "Ever wonder why Red Hat spends so much time focused on the JBoss middleware market and so little time trying to make Linux a desktop standard? The answer involves some simple but startli

Latest Digg Entries

In my Javascript I keep getting "submit is not a function". What did I do?

posted Wednesday, 23 August 2006
If you have a Javascript function, doing some form validation for example, and at the end, it will submit the form, and it suddenly stops working, throwing up an error message in the console box that reads "submit is not a function" then you have probably mis-named one of your form fields.

The most common being that you've accidentally named a submit field as 'submit'.
<input type="submit" name="submit" value=" save ">
This is where the problem is.  When you make a call to submit the form using:
document.getElementById("aform").submit();
It will attempt to call the submit() function of the <input> field and not the <form> of the same name.

resolution inspired from http://www.spiration.co.uk/post/1232

tags:    

links: digg this    del.icio.us    technorati    




1. lsi left...
Saturday, 24 February 2007 12:16 pm

nice, solved my prob!


Related Posts

In my Javascript I keep getting "submit is not a function". What did I do?

Wednesday, 23 August 2006 10:57 A GMT
If you find you keep getting a javascript warning about "submit is not a function" and cannot figure out why then worry no more. Its a subtle issue.