urllib2 web auth issues!!

S

scripteaze

import urllib2

# Create an OpenerDirector with support for Basic HTTP
Authentication...
auth_handler = urllib2.HTTPBasicAuthHandler()
auth_handler.add_password('realm', 'https://www.somesite.com/
loginform.ws?mod=ticketing', 'myid', 'passwd')
opener = urllib2.build_opener(auth_handler)
# install it globally so it can be used with urlopen.
urllib2.install_opener(opener)
urllib2.urlopen('???????????????')

After i login, that page it brings me to looks like this:

'https://ticketing.somesite.com/i=3729336821930248510/inbox.ws'

where 3729336821930248510 is always different. i need a way to let me
know tha login was successful
 

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,777
Messages
2,569,604
Members
45,234
Latest member
SkyeWeems

Latest Threads

Top