Is there a way to get the xpath in google chrome?
I have a webpage I want to use with YQL. But I need the xpath of a specific item. I can see it in the debug tools area for google chrome but I don't see a way to copy that xpath.
Is there a way to copy a full xpath or an extension to do it?
You can use $x
in the Chrome javascript console. No extensions needed.
ex: $x("//img")
Also the search box in the web inspector will accept xpath
右键点击节点=>“复制XPath”
All above answers are correct here is another way with screenshot too.
From Chrome :