1.

What are the types of XPATH?

Answer»

XPATH stands for XMLPath. Using XPath you can navigate to any element in an XML document. As  XML is a component of HTML, XPath can be used to find web elements on any web PAGE. Relative XPath and absolute XPath are two types of XPath.

  • Absolute XPath: Absolute XPath is the direct way to find the element. The disadvantage of the absolute XPath is that for any changes made in the path of the element then that XPath will fail. 
  • Relative XPath: Relative XPath is a URL that CONTAINS a portion of the full path and it is alternatively referred to as a partial path or non-absolute path. A relative path is used to specify the LOCATION of a directory relative to another directory. A relative path starting from the element you want to refer to and GO from there.


Discussion

No Comment Found