Jump to content

IE search tag content <span class="price" id=...></span>


Recommended Posts

Hi, I already read span tag but I have many products into the page, I already know 3445 is a product and it can be a part of variable, but I don´t know how can I read an:

 

Span with class "price" and id "product-price-3445" and get the price 3,753

 

Regards!!!

<span class="price" id="product-price-3445">
                    $3,753                </span>
Local $oPTags_Prod = _IETagNameGetCollection($oIE, "span")
   For $oPTag In $opTags_Prod
      If $oPTag.ClassName = 'price' Then
         ConsoleWrite($oPTag.InnerText & @CRLF)
      EndIf
   Next

 

Link to comment
Share on other sites

??

If $oPTag.ClassName = 'price' And $oPTag.ID = 'product-price-3445' Then

edit:

also, since an ID is "unique" within an html page maybe filtering only on the ID will suffice

If $oPTag.ID = 'product-price-3445' Then

 

Edited by Chimp

 

image.jpeg.9f1a974c98e9f77d824b358729b089b0.jpeg Chimp

small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt....

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...