XPATH: a specific word in a paragraph
I am trying to figure out how to get the exact xpath for example. third word in a paragraph:
eg:.
<p>Here is some text</p>
then if I want the third word ("some") I cannot figure out how to do it using xpath. However, the trick here is not to get an exact match for the word βsomeβ, but to get the third word (whatever it is).
I've tried with this: ../ p [3] but doesn't help. I am using python and scrapy framework.
Hopefully someone can point me in the right direction.
Thank.
+3
source to share