-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
50 lines (32 loc) · 1.08 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
SmartAjaxForm
==========
Lets just send forms via AJAX and display the result. You need only to set the class to "ajaxForm" to your form-tag and it will work.

How to use
----------
Get started by copy this in your head:
window.addEvent('domready', function() {
var mySmartFormObj = new SmartAjaxForm();
});
and add the class "ajaxForm" to your form-tags:
form id="myForm" class="ajaxForm" action="demo.php" method="post"
It is important to make no cross-domain request. So use relative urls in the action attribute.
Syntax
------
new SmartAjaxForm([options])
Arguments
---------
- no Arguments
Options
-------
* regExpClassname: (regexp) To change the CSS class name, for example /^ajaxForm/i -> class='ajaxForm'
* responseClass: (String) CSS class name for the response
* loadingClass: (String) CSS class name for the loading animation
Events
------
- onClick
- onComplete
- onFailure
Contact
-----------
Please contact me ([email protected]) if you have any suggestions or comments.