Download empty php file

16 Jun 2016 PHP Force Download File - Simple script to download a file from directory or server in PHP if(!empty($fileName) && file_exists($filePath)){

This value should ; be increased on systems where PHP opens many files to reflect You can download a copy of the PHP manual from http://php.net/docs ; and PHP's default behavior is to leave this value ; empty. ; http://php.net/error-log 

10 Nov 2018 Firefox may repeatedly open new, empty tabs or windows after you click see Change what Firefox does when you click on or download a file.

There are .htaccess file hacks or apache tricks to achieve this. But not all webhosting companies allow such mods or hacks.

Change: header("Content-Length: ".$fsize);. to: header("Content-Length: ".filesize("upload_doc/$file_get"));. because you never set $fsize . The empty 

I see the same behavior in my RB951G-2HnD - log shows that mikrotik.php was downloaded (I see it in the files section - it is blank php file) 

16 Jun 2016 PHP Force Download File - Simple script to download a file from directory or server in PHP if(!empty($fileName) && file_exists($filePath)){