Re: OT - How to code a link to download a file (program file)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, March 26, 2007 2:49 pm, Rahul Sitaram Johari wrote:
> header("Content-Type: application/force-download");

header("Content-type: asfdsgfhrsiu/luhgireughinfibvn");

would work equally well as application/force-download

> header("Content-Disposition: attachment; filename=".basename($F));
> @readfile($F);
> ?>
>
> $F was the filename passed as a variable.

And if $F is set to /etc/passwd what does your script hand out?

-- 
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some indie artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux