I'm trying to do a post function after gettings some json files.
But when I press the button that trigger the function the result is a get not a post.
function post(info) {
$.ajax({
//type: "POST",
method: "post",
data: info,
url: 'http://www.exefire.com/log',
dataType: "jsonp",
async: true,
success: function(result) {
console.log(result);
},
error: function(request, error) {
var texto = 'Error conectando con el servidor!';
alert(texto);
}
});
}
I don't know what am I doing wrong.