Jump to content
Sign in to follow this  

<span class tags

Recommended Posts

I have searched but can't find anything that works for me - how do I retrieve the text nodes of <span class tags? Here is a canned search to the results I want to capture:


and I want to retrieve each of the text items which are nicely named :

<span class="document-link headline" title="Show Document">CASE OF DE SOUZA RIBEIRO v. FRANCE</span>

<span class="column01">22689/07</span>

<span class="column03">Judgment (Merits and Just Satisfaction)</span>

<span class="column04">Court (Grand Chamber)</span>

<span class="column04">13/12/2012</span>

<span class="fulltext">Preliminary objection joined to merits and dismissed (Article 34 - Victim) Violation of Article 13+8 - Right to an effective remedy (Article 13 - Effective remedy) (Article 8-2 - Interference Prescribed by law Article 8-1 - Respect for family life Respect for private life Article 8 - Right to respect for private and family life Expulsion) (Brazil) Pecuniary damage - claim dismissed Non-pecuniary damage - award</span>

My modified simple script from help seems like it should work for one <span class tag but it doesn't::

#include <IE.au3>
$oIE = _IECreate ('http://hudoc.echr.coe.int/sites/eng/Pages/search.aspx#')
$id = _IEGetObjByName ($oIE, "column01")
$oText1 = _IEPropertyGet($id, "innertext")
MsgBox(0, "Value", $oText1)
_IEQuit ($oIE)

Here is the sites structure if it helps:


Edited by Jury

Share this post

Link to post
Share on other sites

Some error checking would show that your call to _IEGetObjByName is failing. You might want to try something like this:

#include <IE.au3>
$oIE = _IEAttach('http://hudoc.echr.coe.int/sites/eng/Pages/search.aspx#', "URL")

Local $oSpans = _IETagNameGetCollection($oIE, "span")
For $oSpan In $oSpans
If StringLeft($oSpan.className,6) = 'Column' Then
MsgBox(0, "Info", "Class: " & $oSpan.className & " Text: " & $oSpan.innerText)

Share this post

Link to post
Share on other sites

Thanks Adventurer is see this kind of variable


in this forum often and wish I could understand it more - I don't see it in the help pages where it would be something like:

($oIE, "column01")

is any ideas where I could learn more about it? Is it like javascript?

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...