Delivering NAMED pdf files

From: Date: Fri, 19 Oct 2001 09:52:12 +0000
Subject: Delivering NAMED pdf files
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-71565@lists.php.net to get a copy of this message
Hi all, I am delivering my PDF files from a non-internet directory. The file gets delivered but the filename is always changed to the name of the php script. Can anyone tell me how to get the file delivered so that the name stays as it was on the server? My PHP code. This is all the php code I use in my site (so far). ========== <?php $fp1 = "D:\\Pdf\\" . $fp; $len = filesize($fp1); header("Content-type: application/pdf"); header("Content-Disposition: inline; filename=$fp1"); header("Content-Length: $len"); readfile($fp1); ?> ============= Regards George Pitcher, Edinburgh _________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com

« previous php.general (#71565) next »