Good afternoon! I have a web application using Php on the server side, and JS on the client. The JS application sends a request to the php via ajax, the php raises an .ini and returns that value. This in Windows is working perfectly. The problem comes to Linux, a server with Centos7, in which I have no way (I have not found so far) to receive the information. Copy-pasteo the pieces of code where the fault occurs:
<?php
if(isset($_POST["refresco"])):
$properties = parse_ini_file("properties.ini");
$refresh = $properties["refresco"];
echo $refresh;
Ese es el codigo en Php. El llamado JS es:
$(document).ready(function(){
setEventQuery();
setEventQueryFalse()
$.ajax({
url: 'consultaC1.php', //Esta libreria
data: "refresco", //Con este parametro
type: 'post', //Con este tipo de transmision de dato
success: function(response){
var refresh = response * 1000;
console.log(refresh);
actualizarActualTime(refresh);
}
}
);
});
The updateActualTime (refresh) function contains a setInterval () with delay in refresh, as the success returns "", * 1000 throws me a 0, and I end with a super-accelerated loop ...
The .ini contains a line like this: soda = 20
And it is located in the same directory as the .php file
I can not find the problem, which is what could be happening in Linux. If someone could help me ... Thank you very much!