Andrés Suárez wrote:
> I'm trying to scrap http://www.ryanair.com/site/ES/. I'm looking for the
> button "Buscar vuelos". Making a pretty printing of the principal url
> and the iframe containing the button:
> 
> require 'mechanize'
> 
> agent = WWW::Mechanize.new
> prices = agent.get 'http://www.ryanair.com/site/ES/' do |homepage|
>   trip      = agent.click(homepage.iframes.first)
>   tripform  = trip.form_with(:name => 'SBform')
>   pp homepage
>   pp trip
> end
> 
> The results are:
> 
> pp homepage -> http://pastie.org/559295
> pp trip     -> http://pastie.org/559297
> 
> But it doesn't appear a button with the name "Buscar vuelos". Somebody
> can help me?
> 
> Thanks in advance,
> Andrés Suárez

Maybe this can help you.
The button you are looking for is in a iframe. I don't use mechanize but 
I think this is the problem.
I have been playing with the form and firewatir using the iform source 
URL and it works.

Good luck.
-- 
Posted via http://www.ruby-forum.com/.