Opened 12 years ago

Closed 12 years ago

#18007 closed New feature (duplicate)

Support for character sets in HTTP headers (RFC5987)

Reported by: Claude Paroz Owned by: nobody
Component: HTTP handling Version: 1.4
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Currently, Django is converting all HTTP headers to us-ascii (RFC 2616). However, a new RFC is available which defines how to encode character set in header fields (RFC 5987):

http://greenbytes.de/tech/webdav/rfc5987.html

My use case is about setting a filename (which can legitimately be a Unicode string) in the Content-Disposition header:

    response["Content-Disposition"]= "attachment; filename=%s" % fname

Change History (2)

comment:1 by Ramiro Morales, 12 years ago

See also #16470.

comment:2 by Alex Ogier, 12 years ago

Resolution: duplicate
Status: newclosed

I mentioned RFC 5987 in #16470. The general solution will be the same for these two tickets.

Note: See TracTickets for help on using tickets.
Back to Top