[docs] [issue25576] Remove “Content-Type: application/x-www-form-urlencoded; charset” advice

Martin Panter report at bugs.python.org
Sun Nov 8 05:56:36 EST 2015


Martin Panter added the comment:

I think the server bugs referenced by the Mozilla bug are mainly about servers that do not recognize the content type at all, due the the presence of any charset parameter. They probably do something like “if headers['Content-Type'] == 'application/x-www-form-urlencoded' ” without checking for parameters first. So it wouldn’t matter if it was charset=latin-1 or charset=utf-8.

A couple comments in the Mozilla bug say that including “charset” is specified by a HTTP standard, but I suspect this may be a mistake. Perhaps this is the best evidence for my argument, from <http://www.w3.org/TR/html/forms.html#url-encoded-form-data>:

'''
Parameters on the “application/x-www-form-urlencoded” MIME type are ignored. In particular, this MIME type does not support the “charset” parameter.
'''

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue25576>
_______________________________________


More information about the docs mailing list