Opened 6 years ago

Closed 6 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


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):

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 Changed 6 years ago by Ramiro Morales

See also #16470.

comment:2 Changed 6 years ago by Alex Ogier

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