定位红框中的文本内容,此处用到了find_elements_by_css_selector。
组合定位元素表示,标签为啊,class值为KSSActionServer的元素。
content = self.driver.find_element_by_class_name('tabularContents').find_elements_by_css_selector('a[class="KSSActionServer"]')
# print('$$$$$$$$$$$$$$$')
result = []
for search_name in content:
# print(search_name)
name = search_name.text
result.append(name)
print(result)