Reputation: 91
I am trying to get the following information extracted out of a link using XPath, for example:
I have <a href="index.cfm?ag_num=470">LINK TEXT HERE</a>
I would like to select the href value of the link but only anything following ag_num=
So I would end up with 470 for the link above. Any ideas are truly appreciated, thank you!!
Upvotes: 0
Views: 36
Reputation: 52665
You can use below XPath
expression to get required value:
substring-after(//a/@href, "ag_num=")
Upvotes: 2