/*	PAX Form ajax submit demo
	
	The below javascript will add a validator to the form, and enable
	ajax submission.
*/
pax.load.onloaded( function() {

	//	Make form submit via ajax
	pax.form.useAjaxSubmit( pax.$('myForm'), {
		submitButton: pax.$( 'submit_button' ),
		callBack: function ( xml, txt, url ) {
			alert( txt );
		}
	} );
	
	//	Add validation(s) to the form
	//pax.validate.initValidation( 'myForm', {
	//	file_upload: { mask: 'notEmpty', hint: { message: 'You must upload at least one file.', x: 100 } }
	//} );
	
} );
