Getting this error:
Uncaught TypeError: Object [object Object] has no method 'live'
From this JavaScript and jQuery code:
init: function(options) {
var form = this;
if (!form.data('jqv') || form.data('jqv') == null ) {
options = methods._saveOptions(form, options);
// bind all formError elements to close on click
$(".formError").live("click", function() {
//Getting error here:
//Uncaught TypeError: Object [object Object] has no method 'live'
});
}
return this;
};
Why is method live
missing?
.live
was removed in jquery 1.9
See DOCs: http://api.jquery.com/live/
Try using .on
instead:
$(document).on('click', '.formError', function(){
//your event function
});