I'm blocking on some XMLimport I'm doing in a sheet.
So far, the data I've been looking at was quite easy to point at simply using chrome's xpath copy and a few tweaks.
But now, a chunk of what I need is behind a mouse-over on the website and I can't locate it.
From this website wowprogress AF ranking
For example, to get the correct value from that line concerning the character Breakerkill" > "33 I used in Google sheet:
=importxml(A1; "//tr[2]/td[6]/span")
(the A1 cell is where I stored the URL for the sheet)
from that code
<span aria-label="45753 exp" class="hint--bottom-right innerLink" style="font-weight: bold;" xpath="1">33</span>
But now, for my next column, I need that node value aria-label (the "45753 exp" part) and I need assistance.
You are nearly there:
This should locate the value of the aria-label.
Let me know if that solves the problem.
I tried it and it produces this result:
Also, have a play with this or a similar tool https://www.freeformatter.com/xpath-tester.html. It has lots of examples, including locating elements by attribute or finding the value of attributes. Then you can become a mini-expert on the subject!
Also beware of taking
Xpathqueries from the browser dev console. It works on theDoMand in loading the URL it may add missing tags like<tbody>. So if you try to use these queries on the URL contents - they won't work - at least without removing the extra selectors.