Easy way to send unlimited number of forms on a page via Ajax.
The page is not reloaded when the form is submitted. This significantly increases the speed of the site.
Mootools already offers a good implementation. I have just summarized this and adapted it so that all the forms with the class ”ajax form” (<form ….class=’ajaxForm’>) get assigned automatically.
More info at MootoolsForge.

Hi BMo,
I’m quite new to Mootools, so not completely sure about this.
I tried the solution given to J-Luc Durand, that allows the user to close the result by clicking a link. When I tried to integrate the code above I get an error: ‘$(‘ in my Firefox error console, which dissapears after a few seconds.
I changed the code to read: $$(‘#idofyourLink’).addEvent(‘click’,function(){ form_tag.replaces(responseLayer); });
This worked, not sure if it’s the correct way to do it or not, can you advise?
regards
Ian N
oh, sorry. You are right. Use: $$(‘#idofyourLink’)
or $(‘idofyourLink’) without the #.
Great, now it makes sense. It was the # character that confused me. Think I will use this method.
Cheers
Hello and thank you for your job.
i use SmartAjaxForm on my web site and i have a question :
How to close the result( by clicking a link and not wherever in the result
(Sorry for my english)
Hi,
remove the event from the response div:
'events': {'click': function(){
this.fireEvent('click');
form_tag.replaces(responseLayer);
}.pass(form_tag,responseLayer).bind(this)
}
and integrate inside:
onComplete: function(response) {...
$('#idofyourLink').addEvent('click',function(){ form_tag.replaces(responseLayer); });
}
Best regards
BMo
Nice plugin