SCREEN SCRAPE WITHIN SAME DOMAIN?
Posted on 2003-12-04
I am trying to use the Microsoft.XMLHTTP object in asp to screen scrape a page with my domain from another page within my domain.
It doesn't seem to work although if I scrape a page from another doamin it works fine. Do any of you know if it is impossible to use this object in order to scrape a page from within the same domain or does my code need modification.
Any comments would be appreciated.
My code is as follows:
Set objXML = Server.CreateObject("Microsoft.XMLHTTP")
objXML.Open "GET" , strURL , False ,"",""
If Err.Number = 0 Then 'no errors
If objXML.Status = 200 then 'url is valid
strOpen = objXML.ResponseText
Response.Write "Incorrect URL"
Set objXML = Nothing