Please support our Python advertiser: Programming Forums
Views: 3564 | Replies: 3
![]() |
Hi,
I'm writing a client program that downloads data from an HTTP server via urllib, like so:
Nice and simple. Unfortunately, the server only accepts requests with a session ID embedded inside - and I don't know how to open sessions using urllib. I've tried looking in the forums here and elsewhere online, and all I got was very generic info on cookies - nothing specific to Python, really.
Does anyone have experience doing this? Can you send me a link?
EDIT:
I found out about cookielib; I'm seeing what I can do with it now. Will let you know if I get it working. Still open to hints!
I'm writing a client program that downloads data from an HTTP server via urllib, like so:
ufile = urllib.urlopen(urlstring) text = ufile.read() # Do stuff with text
Does anyone have experience doing this? Can you send me a link?
EDIT:
I found out about cookielib; I'm seeing what I can do with it now. Will let you know if I get it working. Still open to hints!
Have you done your required reading on sockets yet?
Here is one article ...
http://www.devshed.com/c/a/Python/Sockets-in-Python/
Also look at the two websites that come up when you run
help('urllib')
Here is one article ...
http://www.devshed.com/c/a/Python/Sockets-in-Python/
Also look at the two websites that come up when you run
help('urllib')
May 'the Google' be with you!
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)






Linear Mode