M
Mario Ruiz
I'm trying to get the text shown in a frame using the text porperty in
firewatir that works for a no-frame window but it doesn't work for a
frame....
A full example using watir and firewatir:
require 'firewatir'
require 'watir'
ie=Watir::IE.new()
ff=FireWatir::Firefox.new()
url="http://www.tlwilliams.net/NOCCC/0005/0005pFrame.html"
frame="menu"
ff.goto(url)
ie.goto(url)
puts "************************ FIREFOX *************************"
myframe=ff.frame(frame)
puts myframe.text()
puts "************************ INTERNET EXPLORER
*************************"
myframe=ie.frame(frame)
puts myframe.text()
ff.close()
ie.close()
The result is:
Starting Firefox using the executable : C:\Program Files\Mozilla
Firefox\firefox.exe
Waiting for 2 seconds for Firefox to get started.
************************ FIREFOX *************************
************************ INTERNET EXPLORER *************************
Web Publishing - Using Frames in HTMLFrames
__5.0_Introduction_to_Frames
__5.1_Using_Frames
__5.2_Complex_Frames
__5.3_Floating_Frames
__5.4_References
As you can see we don't have any text content from firewatir.
Anybody knows how to get the text.. I mean not the html
Thanks.
firewatir that works for a no-frame window but it doesn't work for a
frame....
A full example using watir and firewatir:
require 'firewatir'
require 'watir'
ie=Watir::IE.new()
ff=FireWatir::Firefox.new()
url="http://www.tlwilliams.net/NOCCC/0005/0005pFrame.html"
frame="menu"
ff.goto(url)
ie.goto(url)
puts "************************ FIREFOX *************************"
myframe=ff.frame(frame)
puts myframe.text()
puts "************************ INTERNET EXPLORER
*************************"
myframe=ie.frame(frame)
puts myframe.text()
ff.close()
ie.close()
The result is:
Starting Firefox using the executable : C:\Program Files\Mozilla
Firefox\firefox.exe
Waiting for 2 seconds for Firefox to get started.
************************ FIREFOX *************************
************************ INTERNET EXPLORER *************************
Web Publishing - Using Frames in HTMLFrames
__5.0_Introduction_to_Frames
__5.1_Using_Frames
__5.2_Complex_Frames
__5.3_Floating_Frames
__5.4_References
As you can see we don't have any text content from firewatir.
Anybody knows how to get the text.. I mean not the html
Thanks.