Electron does not recognize Ajax


#1

I’m doing an application with electron, where I need to use Ajax to make a request. When I run the application everything inside the ajax operation does not execute it is as if electron would not allow or recognize ajax.

Does anyone have a solution for this?

Thank you!

This is code:

function comprovaNif(){
var = require('C:\\Users\\autoservei\\Documents\\prova\\jquery-3.1.1.min.js'); .ajax({
url: ‘https://aplicatiudev.spinvilanova.com/aplicatiu/lib/dadesJSONFunc.php?call=ciberIniciSessio&nosession=1&numSerie=pcSpin3&nif=’ + $("#nif").val(),
dataType: ‘json’,
success: function(data){
var potAccedir = data.potIniciarSessio;
var error = data.error;
alert(potAccedir);
}
});
}