Form with JS Validation is not Calling the Form Action

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
JoefromPhilly
Forum Newbie
Posts: 8
Joined: Sat May 31, 2008 3:36 pm

Form with JS Validation is not Calling the Form Action

Post by JoefromPhilly »

I have a form that is embedded in a Wordpress page. The form can be seen here:

http://yellowsheetcoupons.net/get-emailed-coupons/

The first three fields need to be input, then it is to call a processing page to store the data into my database. Right now, I just have a test page that should echo "Submitted".

The problem is that the PHP page never gets called. Any idea as to why? You can see the form code and the JS validation function if you go to the page.

Thanks,

- Joe
User avatar
requinix
Spammer :|
Posts: 6617
Joined: Wed Oct 15, 2008 2:35 am
Location: WA, USA

Re: Form with JS Validation is not Calling the Form Action

Post by requinix »

It does get called... via AJAX. Your script is supposed to return (read: output) JSON that looks like

Code: Select all

{"status":"success"}

Code: Select all

{"status":"error","errors":[something]} // don't know what the "something" is supposed to be
It's doing that because you gave your form class=TTWForm - which seems to be necessary to make the form look the way it does so you can't just remove that.
Post Reply