get xpath of html element

在firefox中有二个非常有用的插件,可以直接得到html页面中元素的XPath:

  1. XPath Checker - suggests XPath and can be used to test XPath results.
  2. Firebug - XPath suggestions are just one of the many powerful features of this very useful add-on.

References

  1. W3Schools XPath Tutorial
  2. W3C XPath Recommendation
  3. XPath Tutorial - with interactive examples