Witam

Mam na stronie downlaods gdzie pobieram zdjecia jpg i dzieje sie cos takiego, ze czasami wysyla sie plik foto.jpg a czasami foto.jpg.html

kod, ktorego uzylem:
  1. header('Content-Type: application/octet-stream');
  2. header('Content-Disposition: attachment; filename=' . $file);
  3. header('Content-Type: application/force-download');
  4.  
  5. readfile(DOCROOT.'/content/downloads/'.$path.'/'.$file);


Jak moge poinformowac przegladarke, ze to JPG i ma nie dodawac html?