Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[solved] screen scraping with firefox - best practices?
#17
I tried the code but still gives an error "Error (RT) in get all links in web page in Firefox: not found. ? "

I can't test the regex in the regex builder because it's used for a proprietary software. Hence, it had the extra weird codes that only works for it and not qm.

Code:
Copy      Help
;;grab source code - this part works

int w=win("Mozilla Firefox" "Mozilla*WindowClass" "" 0x804)
Acc a.Find(w "DOCUMENT" "" "" 0x3010 2)
str html
a.WebPageProp(0 0 html)

;;findrx - find links matching the regex pattern and show it
ARRAY(str) l
int i
str pattern=
;<a class="comment-count" href="(.*)" title="Comments for:

if(0=findrx(html pattern 0 4 l)) end "not found"

for i 0 l.len
    out l[1 i]


Messages In This Thread

Forum Jump:


Users browsing this thread: 5 Guest(s)