From c9f73760ffa41ef938d386e26c6d04d963178c0a Mon Sep 17 00:00:00 2001 From: g1879 Date: Wed, 24 Mar 2021 08:47:50 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E5=96=84=E5=88=87=E5=85=A5iframe?= =?UTF-8?q?=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- DrissionPage/driver_page.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DrissionPage/driver_page.py b/DrissionPage/driver_page.py index d5ae53f..430ca4e 100644 --- a/DrissionPage/driver_page.py +++ b/DrissionPage/driver_page.py @@ -450,7 +450,7 @@ class DriverPage(object): self.driver.switch_to.parent_frame() # 传入id或name - elif ':' not in loc_or_ele and '=' not in loc_or_ele: + elif ':' not in loc_or_ele and '=' not in loc_or_ele and not loc_or_ele.startswith(('#', '.')): self.driver.switch_to.frame(loc_or_ele) # 传入控制字符串