https://www.realestate.com.au/buy/in-ro ... 226/list-1
When I use ReceiveHTTPFile() with it, I get these characters in the downloaded file:

I was just doing this:
Code: Select all
ReceiveHTTPFile("https://www.realestate.com.au/buy/in-robina,+qld+4226/list-1","D:\ReceiveHTTPFile.txt")
Why the difference? It seems to me that I can't rely on ReceiveHTTPFile() to get the HTML of web pages?
Here's the CopyURLText() code that I'm using:
Code: Select all
Procedure WaitForWebGadget(gad)
Browser.IWebBrowser2=GetWindowLongPtr_(GadgetID(gad),#GWLP_USERDATA)
Repeat
While WindowEvent() : Wend
Browser\get_Busy(@busy.l)
If busy=#VARIANT_TRUE : Sleep_(1) : EndIf
Until busy=#VARIANT_FALSE
EndProcedure
Procedure.s CopyURLText(url$)
w=OpenWindow(#PB_Any,0,0,0,0,"",#PB_Window_Invisible)
If w
g=WebGadget(#PB_Any,0,0,0,0,url$)
WaitForWebGadget(g)
text$=GetGadgetItemText(g,#PB_Web_HtmlCode)
CloseWindow(w)
EndIf
ProcedureReturn text$
EndProcedure
Debug CopyURLText("https://www.realestate.com.au/buy/in-robina,+qld+4226/list-1")


