Vikash Kumar wrote:
> I am running a test case, in which I have to first login to a web page
> then I have to go to some particular page in the same web site, then
> extract some data from that page. The data is in the table.
> 
> Such as the script first call http://localhost/login.asp, then we enter
> user name and password, then we click on login button.  By this we enter
> to the web page, then we go to http://localhost/achievements.asp, from
> this page we want to extract the data residing in html table.  What
> should be the approach to do this.
> 
> I can use the below code to extract the data if I have not to login to
> the web site.

In 2 days I am going to release a web extraction toolkit which will do 
exactly what you want (and more of course, but this is a basic use 
case)... It's based on Mechanize (which is used for login like stuff) 
and HPricot for extracting the relevant stuff. The scenario you 
described is an absolutely typical one, so you could try it with my stuff...

I will post here an announcement after the release.

Cheers,
Peter

__
http://www.rubyrailways.com