简体   繁体   English

硒的xpath中的dot(。)是什么意思?

[英]What does dot(.) mean in the xpath of selenium?

What is the difference between the functionality of 功能之间有什么区别

.//input[@id='stack'] and //input[@id='stack'] .//input[@id='stack']//input[@id='stack']

. always represents the current element. 始终代表当前元素。 So your first statement looks for all <input id='stack'> beneath the actual element while the latter globally looks for all input elements with the id 'stack'. 因此,您的第一条语句在实际元素下查找所有<input id='stack'> ,而后者在全局范围内查找所有ID为'stack'的输入元素。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM