Christian Rickert added the comment:

>>Ah, I think I see where you are coming from. I guess you aren’t intimately 
>>familiar with the HTTP protocol.

Exactly. :)


>>If you can given a specific comment line to add to a specific example, that 
>>might be useful. Even if you aren’t 100% sure of the details :)

[OpenerDirector example]
import urllib.request
opener = urllib.request.build_opener()
# adding custom header value to the 'User-agent' key
opener.addheaders = [('User-agent', 'Mozilla/5.0')]
opener.open('http://www.example.com/')

"This is often used to “spoof” the User-Agent header VALUE, which is used by a 
browser to identify itself ..."

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue25570>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to