httplib 的 Python 文档 ( http://docs.python.org/2/library/httplib.html ) 显示了 urllib.urlencode 参数键,前面有一个@
符号。我在其他示例中看不到这一点。在这种情况下,@ 符号在做什么?
>>> import httplib, urllib
>>> params = urllib.urlencode({'@number': 12524, '@type': 'issue'})
>>> headers = {"Content-type": "application/x-www-form-urlencoded",
... "Accept": "text/plain"}
>>> conn = httplib.HTTPConnection("bugs.python.org")
>>> conn.request("POST", "", params, headers)