On Tue, Jun 30, 2009 at 7:41 PM, Martin
Langhoff<martin.langh...@gmail.com> wrote:
> Rename and copy

>From the department of useful tricks...

If you want to preserve your users' ability to name a file you serve
via HTTP, eschew proper mimetypes and say with me:

    Content-Type: application/x-forcedownload

With that mimetype, the "rename and copy" strategy works.

> Is there a better way to do this?

At first blush it doesn't qualify as 'better', but this particular
file is not meant to be read or edited by the end user (as it's
Canonical JSON). So serving it text/plain was a liability, as the
Journal would happily open it under Write.xo . So yes, we are better
off with it.

Maybe application/json-don't-edit-me would be more appropriate.

cheers,


m
-- 
 martin.langh...@gmail.com
 mar...@laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
_______________________________________________
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel

Reply via email to