Commit ac34e09b authored by Martin Panter's avatar Martin Panter

Correct Content-Type syntax in documentation

parent 06622ead
...@@ -1107,7 +1107,7 @@ The code for the sample CGI used in the above example is:: ...@@ -1107,7 +1107,7 @@ The code for the sample CGI used in the above example is::
#!/usr/bin/env python #!/usr/bin/env python
import sys import sys
data = sys.stdin.read() 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`:: Here is an example of doing a ``PUT`` request using :class:`Request`::
......
...@@ -423,10 +423,10 @@ def join_header_words(lists): ...@@ -423,10 +423,10 @@ def join_header_words(lists):
Takes a list of lists of (key, value) pairs and produces a single header Takes a list of lists of (key, value) pairs and produces a single header
value. Attribute values are quoted if needed. value. Attribute values are quoted if needed.
>>> join_header_words([[("text/plain", None), ("charset", "iso-8859/1")]]) >>> join_header_words([[("text/plain", None), ("charset", "iso-8859-1")]])
'text/plain; charset="iso-8859/1"' 'text/plain; charset="iso-8859-1"'
>>> join_header_words([[("text/plain", None)], [("charset", "iso-8859/1")]]) >>> join_header_words([[("text/plain", None)], [("charset", "iso-8859-1")]])
'text/plain, charset="iso-8859/1"' 'text/plain, charset="iso-8859-1"'
""" """
headers = [] headers = []
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment