selenium+python浏览器窗口的切换
1.首先需要知道当前浏览器中有多少个活动的窗口
>>> br.window_handles
[u'{075a54ee-3d10-4c76-b56d-b645259bbd54}', u'{9c3e079a-692d-4add-bf1d-eb732a6a0cc8}']
2.当前的活动窗口是哪个
>>> br.current_window_handle
u'{075a54ee-3d10-4c76-b56d-b645259bbd54}'
2.选择需要切换到的窗口句柄
>>> br.switch_to_window(br.window_handdles[1])
>>> br.current_window_handle
u'{9c3e079a-692d-4add-bf1d-eb732a6a0cc8}'