title: PHP JSON Array empty even if the result query is not empty
body: <p>so i have this php script here.</p>
  
  <pre><code>&lt;?php
  require "conn.php";
  
  $response = array();
  
  $query = "SELECT * FROM groupe_académiques";
  $result = $conn-&gt;query($query);
  $number_of_rows = mysqli_num_rows($result);
  
  
  while ($row = mysqli_fetch_array($result)) {
  
      array_push($response, array("ID"=&gt;$row[0], "Nom"=&gt;$row[1]));
  
  }
  
  echo json_encode($response);
  
  
  ?&gt;
  </code></pre>
  
  <p>And the thing is when i try it it's giving me an empty json array, even if the query is returning some rows.
  I used the same script for another table and it's working i really don't understand it's like there's no error, how can i solve that? thanks for your help.</p>