[Zope] opinions needed on methods for file download...

Phil Harris phil@philh.org
Tue, 27 Jul 1999 08:35:25 +0100


Tone,

There is header you can send which sets the 'real' name of the file to be
downloaded.

I've seen this discussed on the PHP list quite recently, might be worth
doing a search there.

HTH

Phil

phil@philh.org

----- Original Message -----
From: Tony McDonald <tony.mcdonald@ncl.ac.uk>
To: Zope List <zope@zope.org>
Sent: Monday, July 26, 1999 11:14 AM
Subject: [Zope] opinions needed on methods for file download...


> Hi,
> I have a situation where I have a lot of files in a unix directory.
> They are all 'labelled up' in an SQL database which holds data such
> as filename, date_uploaded, owner, version and mimetype.
>
> The output DTML is similar to this at the moment, where log_entries
> is some SQL that returns filename, mimetype and idnum, whilst
> dump_file is a simple external method that puts the right
> content-type header on the data and reads it out to the browser.
>
> <dtml-in log_entries>
> <tr>
> <td><a href=dump_file?filename=<dtml-var filename
> url_quote>&mimetype=<dtml-var mimetype url_quote>><dtml-var
> idnum></a></td>
> <td><dtml-var filename></td>
> <td><dtml-var mimetype></td>
> <td><dtml-var owner></td>
> <td><dtml-var uploaded></td>
> </tr>
> </dtml-in>
>
> The problem is that the URLs are really clunky and the file download
> name is always 'dump_file'. Does anyone have any other thoughts on
> how this might work?
> cheers
> tone
>
> ------
> Dr Tony McDonald,  FMCC, Networked Learning Environments Project
> http://nle.ncl.ac.uk/
> The Medical School, Newcastle University Tel: +44 191 222 5888
> Fingerprint: 3450 876D FA41 B926 D3DD  F8C3 F2D0 C3B9 8B38 18A2
>
> _______________________________________________
> Zope maillist  -  Zope@zope.org
> http://www.zope.org/mailman/listinfo/zope
>
> (To receive general Zope announcements, see:
> http://www.zope.org/mailman/listinfo/zope-announce
>
> For developer-specific issues, zope-dev@zope.org -
> http://www.zope.org/mailman/listinfo/zope-dev )
>