在Splinter中获取href值?

pix*_*xel 5 python href splinter

我想href<a>Splinter的元素中获取价值.

那有什么api方法吗?

Pab*_*ich 11

如果使用find_by_*方法选择元素,则这些实例返回的实例为ElementLists.选择您感兴趣的元素(很可能是ElementAPI实例)后,像字典一样访问该属性:

the_element['href']
Run Code Online (Sandbox Code Playgroud)