ops! i have been a little too slow in typing :)
On Jun 17, 6:03 am, jacknife wrote:
> To continue form submitting you can directly call the submit after the
> ajax validation.
> a quick example could be:
>
> [code]
> var form = $('form_id');
>
> form.observe('submit', function(event){
>
To continue form submitting you can directly call the submit after the
ajax validation.
a quick example could be:
[code]
var form = $('form_id');
form.observe('submit', function(event){
event.stop();
new Ajax.Request(validition_url, {
onSuccess : function(response)
I just got this working! Here's my final JS code. While the form
itself submits to "/search/result/keyword" as the default action,
validation is an entirely different "/search/validate/searchkeyword"
URL.
Event.observe(window, 'load', function()
{
Event.observe('searchkeyword', 'sub
Thanks. This is very helpful.
What if I don't want any success text returned? This is for a search
engine form. If validation passes (search criteria longer than 2
characters, etc), I just want to submit the full form and not have
text returned. Should I somehow be validating against a separat
Hi,
You _might_ be able to get it to work with a synchronous ajax call,
but I wouldn't recommend it, the user experience would be pretty ugly.
(Frozen browser for 2-3 seconds, at least.)
I'd probably rejig things a bit so that validation and submission are
both done at the same time, via ajax: