I made the following code
$data_restante = "SELECT DATEDIFF(CURTIME(),$data) AS date";
$result_data_res = mysqli_query($conn, $data_restante);
$dado_data_res = mysqli_fetch_assoc($result_data_res);
echo $dado_data_res['date'];
But it does not return anything. What is wrong?