mirror of
https://github.com/python/cpython.git
synced 2026-01-08 08:22:41 +00:00
Correct Content-Type syntax in documentation
This commit is contained in:
parent
06622ead80
commit
ac34e09bbf
2 changed files with 5 additions and 5 deletions
|
|
@ -1107,7 +1107,7 @@ The code for the sample CGI used in the above example is::
|
|||
#!/usr/bin/env python
|
||||
import sys
|
||||
data = sys.stdin.read()
|
||||
print('Content-type: text-plain\n\nGot Data: "%s"' % data)
|
||||
print('Content-type: text/plain\n\nGot Data: "%s"' % data)
|
||||
|
||||
Here is an example of doing a ``PUT`` request using :class:`Request`::
|
||||
|
||||
|
|
|
|||
|
|
@ -423,10 +423,10 @@ def join_header_words(lists):
|
|||
Takes a list of lists of (key, value) pairs and produces a single header
|
||||
value. Attribute values are quoted if needed.
|
||||
|
||||
>>> join_header_words([[("text/plain", None), ("charset", "iso-8859/1")]])
|
||||
'text/plain; charset="iso-8859/1"'
|
||||
>>> join_header_words([[("text/plain", None)], [("charset", "iso-8859/1")]])
|
||||
'text/plain, charset="iso-8859/1"'
|
||||
>>> join_header_words([[("text/plain", None), ("charset", "iso-8859-1")]])
|
||||
'text/plain; charset="iso-8859-1"'
|
||||
>>> join_header_words([[("text/plain", None)], [("charset", "iso-8859-1")]])
|
||||
'text/plain, charset="iso-8859-1"'
|
||||
|
||||
"""
|
||||
headers = []
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue