Search found 3 matches

by lwi
Fri Aug 06, 2004 2:37 pm
Forum: PHP - Code
Topic: Content-Length header not working!
Replies: 6
Views: 518

Ok... I downloaded this very useful little gizmo: http://www.blunck.info/iehttpheaders.html . It allows you to view the HTTP headers sent to the browser. It showed me that the content lenght header is actually sent to the browser, which I find odd. Here are the headers: HTTP/1.1 200 OK Date: Fri, 06...
by lwi
Fri Aug 06, 2004 11:53 am
Forum: PHP - Code
Topic: Content-Length header not working!
Replies: 6
Views: 518

the $path variable represents both the path and the file name. In your example there is no space between the size and the word 'bytes'... i assum it's a slight mistake. Either way, I tried both ways: <?php header ('Content-Length: '.$size. "bytes"); ?> and <?php header ('Content-Length: '....
by lwi
Fri Aug 06, 2004 9:53 am
Forum: PHP - Code
Topic: Content-Length header not working!
Replies: 6
Views: 518

Content-Length header not working!

Hi, I have a small problem with a download script I have made. Here is the code: (snipped authentication / anti-leech code) $size = filesize($path); header("Pragma: "); header("Cache-Control: "); header("Content-type: application/octet-stream"); header("Content-Dis...