Andy Davies wrote:
search on the following....
"RE: VFP8: Screen Scrape"
I'd forgotten I wrote that <s~>
and it raises a couple of interesting points about screen scraping:
the code worked when I wrote it, but doesn't now - for two reasons:
the target site has changed slightly
amongst other things this means you end up at a 'redirected default'
page - one of the ms security patches (I think) results in http post
commands being rejected by such pages. Try this:
cURL = "http://www.hawthornecottage.com/andy/" && your url here
oHttp = createobject("Microsoft.XmlHttp")
oHttp.Open("POST", cURL, .F.) && Synchronous
? oHttp.Send("")
gcc= oHttp.ResponseText
n1= AT([NAME="Graphic2"],gcc) && you do
n2=AT('ALT=',SUBSTR(gcc,n1)) && a lot of
n3=AT('" ', SUBSTR(gcc,n1+n2)) && this stuff
?ALLTRIM(SUBSTR(gcc, n1+n2+3, n3-2)) && when screen scraping
ohttp.abort
ohttp=null
CLOSE ALL
CLEAR ALL
RELEASE ALL
Now try the same thing but using "http://andy.hawthornecottage.com" *which
goes to the same page*
- it fails and you get a 405 error
Andy -- I get a 405 error with both examples...neither works for me. ???
--Michael
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
** All postings, unless explicitly stated otherwise, are the opinions of the
author, and do not constitute legal or medical advice. This statement is added
to the messages for those lawyers who are too stupid to see the obvious.