mirror of
https://github.com/django/django.git
synced 2025-08-03 02:23:12 +00:00
Fixed #19006 - Quoted filenames in Content-Disposition header.
This commit is contained in:
parent
1c03b23567
commit
234ca6c61d
3 changed files with 6 additions and 6 deletions
|
@ -590,7 +590,7 @@ To tell the browser to treat the response as a file attachment, use the
|
|||
this is how you might return a Microsoft Excel spreadsheet::
|
||||
|
||||
>>> response = HttpResponse(my_data, content_type='application/vnd.ms-excel')
|
||||
>>> response['Content-Disposition'] = 'attachment; filename=foo.xls'
|
||||
>>> response['Content-Disposition'] = 'attachment; filename="foo.xls"'
|
||||
|
||||
There's nothing Django-specific about the ``Content-Disposition`` header, but
|
||||
it's easy to forget the syntax, so we've included it here.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue