The following warnings occurred: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Warning [2] Undefined array key "avatartype" - Line: 783 - File: global.php PHP 8.1.31 (Linux)
|
Validation & Multipage Forms - Printable Version +- Form Tools (https://forums.formtools.org) +-- Forum: Modules / Other (https://forums.formtools.org/forumdisplay.php?fid=8) +--- Forum: Form Validation: JS + PHP (https://forums.formtools.org/forumdisplay.php?fid=18) +--- Thread: Validation & Multipage Forms (/showthread.php?tid=232) |
Validation & Multipage Forms - Martin_Dee - Aug 7th, 2009 Hi, I've tried searching the old forums, but I've not been able to see an answer to this. I intend to have a multi-page from - my question is when do I bring the js and php validation into play? I imagine that I need to do the js validation at the 'continue' and 'submit' button stages on each page - is that correct? But with the php validaiton, how do I handle an error from say the first page (which is no longer visible)? Should I be looking at bringing the form back for 'review' before running the php validation? Any suggestions appreciated. Martin RE: Validation & Multipage Forms - Ben - Aug 7th, 2009 Hi Martin, Give this tutorial a read: it explains how to add PHP validation to your forms. http://docs.formtools.org/tutorials/php_validation/ It only covers a single page form (with the API) but the principle works exactly the same for each page in a multi-page form. The JS validation works the same regardless of the form type - API, POST, multi-page, single-page - anything! Here's a tutorial on that, too! http://docs.formtools.org/tutorials/js_validation/ Let me know if you have any trouble. - Ben RE: Validation & Multipage Forms - Martin_Dee - Aug 10th, 2009 Hey Ben, I've read the tutorials again and I'm now having a crack at getting my form working (I may be back in touch!). I also wanted to say what a great piece of software you've built. Thank you and I will get round to donating! Best regards Martin |