//Finish off
session_destroy();
error_reporting(2039);
?>
For some reason IE says the file will download as an HTML file when in fact its an image file which is corrupt I think I have get the code in the wrong places, can anyone help me clear this up?
__________________ Alexa Share <-- Trade virtual shares in websites with this online game.
codR.us <-- Submit and vote for your favorite code snippets with codR.us.
I suggest you first debug the value of the $tmp variable; I believe it contains only file name without the extension. Also check this script with other browsers. Besides, I don't think it's a good idea to have filename="files/myfile" in the Content-Disposition: header.
__________________ onPHP5.com - PHP5: Articles, News, Tutorials, Interviews, Software and more