使用Chrome浏览器的XPath元素? [英] XPath for elements using Chrome?
本文介绍了使用Chrome浏览器的XPath元素?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
是否可以使用 Chrome开发人员工具(DevTools)来获取UI元素的XPath? 我想在Selenium UI自动测试中使用XPath.
Is there a way to get XPath of UI elements using Chrome Developer Tools (DevTools)? I want to use the XPath in Selenium UI auto-testing.
推荐答案
-
将光标放在元素上
Place the cursor on the element
执行右键单击,然后单击检查".您将看到您的元素被突出显示
Perform right click and click on Inspect. You will see your elements getting highlighted
- 在控制台的元素"选项卡下突出显示的元素上,右键单击并复制xpath,如下图所示:
这篇关于使用Chrome浏览器的XPath元素?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文