authentication example with urllib.request

L

larryzhang

Dear all,

I am trying to download data from a website that requires
authentication (maybe with cookies). Any suggestions on how i can do
this with the urllib.request module in py3? Where can I can find some
working examples? Thanks a lot.

Larry
 
M

Marco Bizzarri

Dear all,

I am trying to download data from a website that requires
authentication (maybe with cookies). Any suggestions on how i can do
this with the urllib.request module in py3? Where can I can find some
working examples? Thanks a lot.

Larry


Hi, Larry.

Did you get a look at library documentation? If you take a look at
http://docs.python.org/3.0/library/urllib.request.html, FancyURLOpener
could do the job for you... (once you subclass it, and redefine the
promp_user_password method).

Regards
Marco
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,756
Messages
2,569,540
Members
45,025
Latest member
KetoRushACVFitness

Latest Threads

Top