per page, with , order by , clip by
Results of 1 - 10 of about 14 for Disposition (0.004 sec.)
CSVを出力する 12533
CSVを出力する このドキュメントでは、Django のビューを使って動的に CSV (Comma Separated Values) を出力する方法を説明しています。そのためには、Python のCSV ライブラリか Django のテンプレートシステムを使います。 Python の CSV ライブラリを使う ... esponse object with the appropriate CSV header. response = HttpResponse ( content_type = "text/csv" , headers = { "Content-Disposition" : 'attachment; filename="somefilename.csv"' }, ) writer = csv . writer ( response ) writer . writerow ([ "First row" , "F ... 解釈し、ブラウザウィンドウに醜くて恐ろしいぐちゃぐちゃの文字列が現れてしまう恐れがあります。 レスポンスには、追加の Content-Disposition ヘッダに CSV のファイル名を設定することができます。ファイル名はどんなものでも構いません。ここで指定した名前は、ブラウザが「 ... for row in batch ) return StreamingHttpResponse ( stream_batched_rows (), content_type = "text/csv" , headers = { "Content-Disposition" : 'attachment; filename="somefilename.csv"' }, ) テンプレートシステムを使う もしくは、 Django のテンプレートシステム を使 ...
https://man.mtool.work/django/6.1/howto/outputting-csv.html
Django 3.2.15 リリースノート 10678
Django 3.2.15 リリースノート 2022年8月3日 Django 3.2.15 では 3.2.14 における深刻度 "high" のセキュリティの問題を修正しました。 CVE-2022-36359: Potential reflected file download vulnerability in FileResponse An application may have been vuln ... erable to a reflected file download (RFD) attack that sets the Content-Disposition header of a FileResponse when the filename was derived from user-supplied input. The filename is now escaped to avoid this ...
https://man.mtool.work/django/6.1/releases/3.2.15.html
Django 4.0.7 リリースノート 10678
Django 4.0.7 リリースノート 2022年8月3日 Django 4.0.7 では 4.0.6 における深刻度 "high" のセキュリティの問題を修正しました。 CVE-2022-36359: Potential reflected file download vulnerability in FileResponse An application may have been vulnera ... ble to a reflected file download (RFD) attack that sets the Content-Disposition header of a FileResponse when the filename was derived from user-supplied input. The filename is now escaped to avoid this ...
https://man.mtool.work/django/6.1/releases/4.0.7.html
PDFファイルを作成する 9435
PDFファイルを作成する このドキュメントでは、Django のビューを使用して PDF ファイルを動的に出力する方法を説明します。これは、優れたオープンソースの Python PDF ライブラリ ReportLab により可能になっています。 PDF ファイルを動的に生成する利点は ... ello world." ) # Close the PDF object cleanly, and we're done. p . showPage () p . save () # FileResponse sets the Content-Disposition header so that browsers # present the option to save the file. buffer . seek ( 0 ) return FileResponse ( buffer , as_attac ... イナリコンテンツではなく、PDFファイルであることを伝えます。 as_attachment=True が FileResponse に渡されると、適切な Content-Disposition ヘッダが設定され、ウェブブラウザはそのマシンでデフォルトが設定されていたとしても、そのドキュメントをどのように扱うかを確認 ...
https://man.mtool.work/django/6.1/howto/outputting-pdf.html
リクエストとレスポンスのオブジェクト 9120
リクエストとレスポンスのオブジェクト 簡単な概要 Django は、システムを通じてステータスを渡すために、リクエストとレスポンスのオブジェクトを使います。 あるページがリクエストされたとき、Django はリクエストに関するメタデータを含んだ HttpRequest ... うようにブラウザに指示します。 ブラウザにレスポンスをファイル添付として扱うように指示するためには、 Content-Type と Content-Disposition ヘッダを設定します。例えば、Microsoft Excel スプレッドシートを返す方法は以下のようになります: >>> response = HttpResponse ... ( ... my_data , ... headers = { ... "Content-Type" : "application/vnd.ms-excel" , ... "Content-Disposition" : 'attachment; filename="foo.xls"' , ... }, ... ) Content-Disposition ヘッダについては Django 固有のものはありませんが、そ ... .file_wrapper を使用し、そうでない場合はファイルを小さなチャンクでストリーミングします。 as_attachment=True だと、 Content-Disposition ヘッダーが attachment に設定され、ブラウザにファイルをダウンロードするように要求します。それ以外の場合は、ファイル名が利用 ...
https://man.mtool.work/django/6.1/ref/request-response.html
Django 1.4.13 リリースノート 9120
Django 1.4.13 リリースノート May 14, 2014 Django 1.4.13 fixes two security issues in 1.4.12. Caches may incorrectly be allowed to store and serve private data In certain situations, Django may allow caches to store private data related to a ... rom the response. In addition, modifications to the Cache-Control header for all Internet Explorer requests with a Content-Disposition header have also been removed as they were found to have similar issues. Malformed redirect URLs from user input not corre ...
https://man.mtool.work/django/6.1/releases/1.4.13.html
Django 1.5.8 リリースノート 9120
Django 1.5.8 リリースノート May 14, 2014 Django 1.5.8 fixes two security issues in 1.5.8. Caches may incorrectly be allowed to store and serve private data In certain situations, Django may allow caches to store private data related to a pa ... rom the response. In addition, modifications to the Cache-Control header for all Internet Explorer requests with a Content-Disposition header have also been removed as they were found to have similar issues. Malformed redirect URLs from user input not corre ...
https://man.mtool.work/django/6.1/releases/1.5.8.html
Django 1.4.2 リリースノート 8805
Django 1.4.2 リリースノート October 17, 2012 This is the second security release in the Django 1.4 series. Host header poisoning Some parts of Django -- independent of end-user-written applications -- make use of full URLs, including domain ... rmissions in templates (#18979) Fixed some Python 2.5 compatibility issues Fixed an issue with quoted filenames in Content-Disposition header (#19006) Made the context option in trans and blocktrans tags accept literals wrapped in single quotes (#18881). Nu ...
https://man.mtool.work/django/6.1/releases/1.4.2.html
Django 1.6.5 リリースノート 8805
Django 1.6.5 リリースノート May 14, 2014 Django 1.6.5 fixes two security issues and several bugs in 1.6.4. Issue: Caches may incorrectly be allowed to store and serve private data In certain situations, Django may allow caches to store priv ... rom the response. In addition, modifications to the Cache-Control header for all Internet Explorer requests with a Content-Disposition header have also been removed as they were found to have similar issues. Issue: Malformed redirect URLs from user input no ...
https://man.mtool.work/django/6.1/releases/1.6.5.html
Django ユーティリティ (django.utils) 7562
Django ユーティリティ ( django.utils ) このドキュメントは、 django.utils のすべての安定したモジュールを対象としています。 django.utils 内のほとんどのモジュールは内部使用を目的としていることから、 内部リリース非推奨ポリシー に従い、以下に記載 ... に設定された場合、デフォルトでは現在時刻になります。 次の形式で文字列を出力します: Wdy, DD Mon YYYY HH:MM:SS GMT 。 content_disposition_header ( as_attachment , filename ) [ソース] RFC 6266 に指定された filename から Content-Disposition HTTPヘッダー値を構築し ... ます。 as_attachment が False でかつ filename が None の場合は None を返し、それ以外の場合は Content-Disposition HTTPヘッダーに適した文字列を返します。 base36_to_int ( s ) [ソース] base36 文字列を整数に変換します。 int_to_base36 ( i ) ...
https://man.mtool.work/django/6.1/ref/utils.html
PREV 1 2 NEXT