I have a code to download zip files:
$dl_path = \'./\';
$filename = \'favi.zip\';
$file = $dl_path.$filename;
if (file_exists($file)) {
header(\'Cont
First of all check if your script is running under the correct directory by echoing dirname(__FILE__)
.
If it is running under public_html
then you can change the code like this:
$dl = dirname(__FILE__). '/../';
But beware of security issue!
open_basedir
restriction in php.ini
(see How can I relax PHP's open_basedir restriction?)Hope this helps