title: PHP Excel - The file you are trying to open .xls is in a different format than specified by the file extension
body: <p>Good Morning,</p>
  
  <p>I am use a API JASPER "JasperClient.php" where i use the function runReport to return a xls and in php code i want to download Excel File from the server.</p>
  
  <p>Setting the header:</p>
  
  <p>header('Content-type: application/vnd.ms-excel');
  header('Content-Disposition: attachment; filename=myfile.xls');</p>
  
  <p>When i'm download the file and try to open the says:</p>
  
  <p>The file you are trying to open, 'filename.xls', is in a different format than specified by the file extension. Verify that the file is not corrupted and is from a trusted source before opening the file. Do you want to open the file now?</p>
  
  <p>Can you help me please? 
  Thank you .</p>