Answer the question
In order to leave comments, you need to log in
Ajax. Where is the mistake?
I can't figure out where the error is. I did this 100500 times and everything worked, and then suddenly it gives out
common.js:4 Uncaught SyntaxError: Unexpected token :
var $form = $('#reg').serialize();
$.ajax(function() {
url: 'app/helper/auth.help.php',
method: 'POST',
data: $form,
success: function(data) {
console.log(data);
},
error: function (xhr, status, error) {}
});
Answer the question
In order to leave comments, you need to log in
var $form = $('#reg').serialize();
$.ajax({
url: 'app/helper/auth.help.php',
method: 'POST',
data: $form,
succes: function(data) {
console.log(data);
},
error: function (xhr, status, error) {}
});
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question