It is possible that in some browsers you install it to automatically download and run this particular type of file.
If so, it is impossible to βfixβ it. The browser decides what to do with the file, even if you tell it to download it, the user could say that it starts directly.
Big board
As long as my previous comment is correct, you have a serious problem in your code:
$file_size = filesize($fileLocation); echo 'Please wait downloading the file....'; header('Content-Description: File Transfer');
You must remove this echo statement. It should cause problems, such as headers that are not sent. Given your description, I would say that this is your problem.
See, as soon as you submit any content, you cannot send more headers.
Christian
source share