Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Enumerate Elements on webpage
#2
Macro Macro1443
Code:
Copy      Help
str s
IntGetFile "http://www.google.com" s
out
HtmlDoc d.InitFromText(s)
ARRAY(MSHTML.IHTMLElement) aLinks aImages
d.GetHtmlElements(aLinks "a")
d.GetHtmlElements(aImages "img")

int i
out "-----Links-----"
for i 0 aLinks.len
,out aLinks[i].getAttribute("href" 2)
out "-----Images----"
for i 0 aImages.len
,out aImages[i].getAttribute("src" 2)


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)