Re: download binary files to browser

From: Stephen van Egmond <svanegmond(at)bang(dot)dhs(dot)org>
To: Louis Bertrand <louis(at)bertrandtech(dot)on(dot)ca>
Cc: pgsql-php(at)postgresql(dot)org
Subject: Re: download binary files to browser
Date: 2001-01-07 17:41:37
Message-ID: 20010107124137.C21271@bang.dhs.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-php

Louis Bertrand (louis(at)bertrandtech(dot)on(dot)ca) wrote:
> What headers can I send to fill in that file name?

Look at content-disposition in the HTTP RFC.

I do this in a similar application:
header("Content-Disposition: attachment; filename=\"$original_name\"");

it helps on the end-user side if you also report the correct
MIME type for the document (i.e. application/msword).

header("Content-type: $mime");

In response to

Responses

Browse pgsql-php by date

  From Date Subject
Next Message Louis Bertrand 2001-01-07 18:12:46 Re: download binary files to browser
Previous Message Louis Bertrand 2001-01-07 17:36:31 download binary files to browser