urllib.request.install_opener(opener)
Install an OpenerDirector
instance as the default global opener. Installing an opener is only necessary if you want urlopen to use that opener; otherwise, simply call OpenerDirector.open()
instead of urlopen()
. The code does not check for a real OpenerDirector
, and any class with the appropriate interface will work.
Please login to continue.