This works for me.

Some of my users (and me on some PCs) get a message alerting them about an
Active-X component, but if you ignore it, it has no affect,

$fpd = "path2file" . $fp . ".pdf";
$len = filesize($fpd);
header("Content-Type: application/pdf"); // change to suit your file type
header("Content-Disposition: inline; filename=$fpd");
header("Content-Title: $fpd");
header("Content-Length: $len");


> -----Original Message-----
> From: Ohlson Stefan [mailto:[EMAIL PROTECTED]]
> Sent: 12 February 2003 10:05 am
> Subject: [PHP-DB] BinaryWrite in PHP?
> Hi!
> I want to let the user to be able to open or save a textdocument with
> text that I create on the fly with some select-statements.
> You know when you click on a button or a link and you get a question
> if you what to Open the file or or Save it.
> In ASP I can use Response.BinaryWrite, how can I do it in PHP?
> Thanks!
> --
> PHP Database Mailing List (
> To unsubscribe, visit:

PHP Database Mailing List (
To unsubscribe, visit:

Reply via email to