@browser.frame(:id => "FrameA").frame(:id =>"FrameA").iframe(:id => "framepage").div(:class => "TblMgmt") works for me using webdriver but not with page-object - don't know how to specify frameset. It's not in the page-object documentation.
On Tuesday, March 27, 2012 9:32:26 AM UTC-7, Chuck van der Linden wrote: > > 1) can you show us the HTML? > > 2) in what you tried above I would not expect it to work since you are > neglecting the second item in the nesting (the frameset with id = > 'treeMain') did you try that same sort of thing in webdriver to see if it > would work? e.g. > > @browser.frame(:id => "FrameA").frame(:id =>"FrameA").iframe(:id => > "framepage").div(:class => "TblMgmt") > > 3) You might file a compatibility bug regarding the use of Frames and > Framesets which are no longer supported as of > HTML5<http://www.w3.org/TR/html5-diff/#absent-elements>, > and throws browsers like IE9 into 'quirks' mode resulting in slower page > loads etc. A page using old HTML tech like that is far more likely to > experience issues with modern browsers. They should move to using iframes > and control the layout and location via CSS and/or javascript. > Incidentally in the latest rdoc I don't even see a frameset method in > watir-webdriver > > 4) am I the only one here that wants to have a public flogging of > developers who nest frames 4 or more levels deep? > > On Monday, March 26, 2012 2:39:55 PM UTC-7, Rick wrote: >> >> Am using page-object 0.6.3 and need to locate a div within an iframe >> which in turn is inside a series of frame->frame->frameset. With >> watir-webdriver, div is located with @browser.frame(:id => >> "FrameA").frameset(:id => "treeMain").frame(:id =>"FrameA").iframe(:id => >> "framepage").div(:class => "TblMgmt") >> >> Tried the following using page-object, but it didn't work - frameset is >> not a supported element in page-object currently >> >> in_frame(:id => 'FrameA') do |frame| >> in_frame({:id => 'FrameA'}, frame) do |frame| >> in_frame({:id => 'framepage'}, frame) do |frame| >> div(:tblstatus, :class => "TblMgmt", :frame => frame) >> end >> end >> end >> >> Is there any other trick, i can try? >> >> Thanks. >> >> >> -- Before posting, please read http://watir.com/support. In short: search before you ask, be nice. [email protected] http://groups.google.com/group/watir-general [email protected]
