[Python-checkins] cpython (3.4): Correct Content-Type syntax in documentation
martin.panter
python-checkins at python.org
Fri Nov 13 21:08:58 EST 2015
https://hg.python.org/cpython/rev/688bfec53c46
changeset: 99121:688bfec53c46
branch: 3.4
parent: 99115:92f989bfeca2
user: Martin Panter <vadmium+py at gmail.com>
date: Sat Nov 14 00:58:32 2015 +0000
summary:
Correct Content-Type syntax in documentation
files:
Doc/library/urllib.request.rst | 2 +-
Lib/http/cookiejar.py | 8 ++++----
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/Doc/library/urllib.request.rst b/Doc/library/urllib.request.rst
--- a/Doc/library/urllib.request.rst
+++ b/Doc/library/urllib.request.rst
@@ -1107,7 +1107,7 @@
#!/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`::
diff --git a/Lib/http/cookiejar.py b/Lib/http/cookiejar.py
--- a/Lib/http/cookiejar.py
+++ b/Lib/http/cookiejar.py
@@ -423,10 +423,10 @@
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 = []
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list