Newbie: HTTP, sessions and Ruby

Y

Yannick Turgeon

Hello all,

I've got a script written in Perl that I have to modify. I'm planning to
completely rewrite it using Ruby. The three main reasons to do this are:
1- My script has to be modified.
2- Perl is too "unclear" for me to find it pleasant to work with.
3- I want to give a try programming with Ruby. I've been charmed recently
with Python and now looking at Ruby doc it seems to be a pretty interesting
language.

What my script is doing:
1- It logs in Yahoo website using my user and password
2- It tooks some webpages there and do some process to extract information.
3- It updates a database with this information.

While looking at Ruby doc, I feel at ease to jump in with almost all the
work to be done except the Yahoo login and session management. Perl has a
great module to do this kind of work (LWP::UserAgent) but I suppose Ruby too
can acheive this. How? Is there any module more specific than Net::HTTP or
Net::HTTPS? If not, how am I suppose to use it? I mean, I get Yahoo login
page, extract all hidden parameter and "post" it with my username and
password, then... I don't understand the big picture to how should I manage
sessions in this case. Are cookies used?

How Yahoo knows if I'm logged or not and what do I have to do to manage
this? Any help or suggestion is welcome.

Thanks

Yannick
 

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

No members online now.

Forum statistics

Threads
473,776
Messages
2,569,602
Members
45,182
Latest member
BettinaPol

Latest Threads

Top