I'm starting to use AJAX now, so I do not know if this is what's going on with it. I made this code to do a CPF search in the database
$('#btn_buscar_cpf_responsavel').on('click', function(){
var cpf = $('#aluno_responsavel_cpf').val();
if (cpf == '') {
alert('Informe um CPF');
} else {
$.ajax({
url: '192.168.0.26/cvt-sergipetec/utils/verify_responsavel_cpf',
type: 'POST',
data: {'cpf' : cpf},
dataType: 'json',
success: function(data) {
if ($.isEmptyObject(data)) {
alert('Responsável não cadastrado');
$('#responsavel_novo').val(1);
} else {
$('#aluno_responsavel_nome').val(data[0].responsavel_nome);
var rg_uf = data[0].responsavel_rg + '/' + data[0].responsavel_rg_uf;
$('#aluno_responsavel_rg').val(rg_uf);
}
},
error: function() {
alert('Ocorreu um erro' + Error);
}
});
}
});
And I want it to send POST to this URL, but it is completing the URL where it was called the most that I passed in the pod, and it looks like this:
Is there any way for it to not start the URL with http://192.168.0.26/cvt-sergipetec/alunos
?