On 14 Nov 2005, at 19:01, Richard Lynch wrote:
It may not be my final choice whether they download or not, but if a
browser doesn't treat:
application/octet-stream
as a download, and only as a download, then that browser is pretty
broken.
Letting the user configure their browser for that MIME t
On Sun, November 13, 2005 4:55 pm, Todd Cary wrote:
> Because this was just a test of what will be many "print" lines. The
> original application used a file to hold the data and upon request by
> the user, it was emailed. But with my client's shared server, files
> cannot be opened...a pain.
>
>
On Sun, November 13, 2005 1:53 pm, Marcus Bointon wrote:
> On 13 Nov 2005, at 19:27, Jasper Bryant-Greene wrote:
>
>>> Many thanks! I did not know that MIME-Type. Change duly made!
>>
>> You're not suggesting that you actually set the MIME-Type to
>> application/force-download, are you?
>
> I
On Sun, November 13, 2005 8:20 am, Marcus Bointon wrote:
>
> On 13 Nov 2005, at 00:17, Jasper Bryant-Greene wrote:
>
>>> seem to do that. I just tried "application/text" since I use
>>> "application/pdf" for other applications.
>>
>> Whatever it's giving the user the ability to do, it's probably
>
Because this was just a test of what will be many "print" lines. The
original application used a file to hold the data and upon request by
the user, it was emailed. But with my client's shared server, files
cannot be opened...a pain.
If you have a better solution, I am open to other ideas.
call me stupid, but why don't you do it like this:
$buf = "This is a test";
header("Content-type: text/plain");
header("Content-Length: ".strlen($buf));
header("Content-Disposition: attachment; filename=sfyc.html");
echo $buf;
??
looks easier to me... no output buffering required...
Todd Cary w
Just before the police knocked at my door, I made a few changes!
";
$buf = ob_get_contents();
$len = strlen($buf);
ob_end_clean();
header("Content-type: text/plain");
header("Content-Length: $len");
header("Content-Disposition: attachment; filename=sfyc.html");
print($buf);
?>
Tod
On 13 Nov 2005, at 19:27, Jasper Bryant-Greene wrote:
Many thanks! I did not know that MIME-Type. Change duly made!
You're not suggesting that you actually set the MIME-Type to
application/force-download, are you?
I think he is. I've called the MIME-type police and they'll be round
lat
Todd Cary wrote:
Marcus -
Many thanks! I did not know that MIME-Type. Change duly made!
You're not suggesting that you actually set the MIME-Type to
application/force-download, are you?
Todd
Marcus Bointon wrote:
On 13 Nov 2005, at 00:17, Jasper Bryant-Greene wrote:
seem to do that
Marcus -
Many thanks! I did not know that MIME-Type. Change duly made!
Todd
Marcus Bointon wrote:
On 13 Nov 2005, at 00:17, Jasper Bryant-Greene wrote:
seem to do that. I just tried "application/text" since I use
"application/pdf" for other applications.
Whatever it's giving the user
On 13 Nov 2005, at 00:17, Jasper Bryant-Greene wrote:
seem to do that. I just tried "application/text" since I use
"application/pdf" for other applications.
Whatever it's giving the user the ability to do, it's probably
because the browser doesn't recognise the (invalid) MIME-Type.
Quit
Todd Cary wrote:
Yup! It was the missing parentheses! Works as planned.
Many thanks
The "application/text" gives the user the ability; "text/plain" does not
The ability to...?
seem to do that. I just tried "application/text" since I use
"application/pdf" for other applications.
Wh
Yup! It was the missing parentheses! Works as planned.
Many thanks
The "application/text" gives the user the ability; "text/plain" does not
seem to do that. I just tried "application/text" since I use
"application/pdf" for other applications.
Todd
Jasper Bryant-Greene wrote:
Todd Ca
-Original Message-
From: Jasper Bryant-Greene [mailto:[EMAIL PROTECTED]
[snip]
application/text isn't a MIME-Type, is it? Do you mean text/plain?
[/snip]
Or maybe text/html?
Sent: 12 November 2005 22:46
To: Todd Cary
Cc: php-general@lists.php.net
Subject: Re: [PHP] Printing
Todd Cary wrote:
My client's new shared server does not allow printing to a file, so I
want my print statement to print to a buffer, then I'll send it to the
user via Headers. This does not work since "print" does no go to the
buffer, or at least appears not to: I get the errors from the heade
15 matches
Mail list logo