下面是html代码..
<iframe id="I0_1366100881331" frameborder="0" width="100%">
<div class="ZRa">
<span id="button" class="hAa Qo Bg" tabindex="0" role="button" title="" aria- label="Click here to publicly +1 this." aria-pressed="false">
</div>
</iframe>
Run Code Online (Sandbox Code Playgroud)
在上面的场景中,我想切换到IFRAME(iframe id ="I0_1366100881331")以对该IFRAME中存在的SPAN执行某些操作.我已经尝试了大多数情况但没有结果:( ......任何人请帮忙.
我想要仅使用水豚红宝石的黄瓜解决方案..
注意:我尝试使用以下代码,但没有结果.
page.driver.browser.switch_to.frame"I0_1366100881331"
Ant*_*0ha 28
within_frame(find('<css rule>')) do
<code for dealing with iframe entries>
end
Run Code Online (Sandbox Code Playgroud)
oiv*_*doo 13
我想你可以尝试使用方法:
within_frame 'id' do
<code for dealing with iframe entries>
end
Run Code Online (Sandbox Code Playgroud)