From ac34e09bbfe59e0d2075be7db317b91da6ca2c69 Mon Sep 17 00:00:00 2001 From: Martin Panter Date: Sat, 14 Nov 2015 00:58:32 +0000 Subject: [PATCH] Correct Content-Type syntax in documentation --- 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 index 74f3c1f142..4df0f568c8 100644 --- a/Doc/library/urllib.request.rst +++ b/Doc/library/urllib.request.rst @@ -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`:: diff --git a/Lib/http/cookiejar.py b/Lib/http/cookiejar.py index dbd34d28ff..cad6b3ac60 100644 --- a/Lib/http/cookiejar.py +++ b/Lib/http/cookiejar.py @@ -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 = [] -- 2.40.0