Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

 
 
Thread Tools Display Modes
Prev Previous Post in Thread   Next Post in Thread Next
Old May 19th, 2006, 10:34 PM   #1
dxLo
Newbie
 
Join Date: May 2006
Posts: 1
Rep Power: 0 dxLo is on a distinguished road
Maintaining connection with URLLIB

Hello everyone, I'm a new comer... and

I am new to Python and still trying to learn its libraries.

Lately I am trying to write a program that automate the process of a browser game [php based]. Normally, a user can supply the website login page with a login name and password, plus some seeds [ not controlled by client , but viewable ]. Then it saves a cookie and continue to surf in the game in that session.

I am trying to do the same in a program. But unfortunately, I can simulate only to the fact I pass the string of login data ( and its seeds ), so basically I login for each page change/refresh and it is very inefficient. And until a stage I need to pass secondary data. I discovered it is impossible to do so without maintaining a connection.

urllib.urlopen('www.site.com', <login data + secondary data>)

Would anyone guide me to the way to maintain a connection so I do not need to connect each time?

I am using URLLIB to do the job. And if there is a good tutorial to explaining the details I would pretty appreciate it.

Thanks very much.
dxLo is offline   Reply With Quote
 

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 9:06 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC