Skip to content

Latest commit

 

History

History
41 lines (28 loc) · 915 Bytes

README.textile

File metadata and controls

41 lines (28 loc) · 915 Bytes

jQuery AutoSaveForm

NO COPYRIGHTS OR LICENSES. DO WHAT YOU LIKE.

USAGE: setting up any number of forms, just add the class ‘autosave’


<form action="..." class="autosave ...">...</form>

USAGE: status note (if it doesn’t exist, automatically added)

Inside the form, create an empty element of any type with a class of `autosave-status`


<form action="..." class="autosave ...">...
<span class="autosave-status muted"></span>
</form>

USAGE: custom callbacks


$('#myform').on('saved', function(e) {
	console.log('autosave complete', e);
});

CONFIGURATIONS


<form action="..." class="autosave ..."
	data-autosave-save-interval="30"
	data-autosave-status-interval="1"
	>...</form>