Download Jpg file from HTTP (or binary)

Find quick help here to get you started with Hollywood
Post Reply
Sheeva700
Posts: 27
Joined: Sun Mar 22, 2015 8:24 pm

Download Jpg file from HTTP (or binary)

Post by Sheeva700 »

Hi,

I'm trying to download a single jpg file from an http location with this code.

SendData(2,"GET http://IP:PORT/icon.jpg".." HTTP/1.1\r\n\r\n")
icon$ = ReceiveData(2,#RECEIVEALL)
debugprint(icon$)

is working fine but i receive also the http header then the jpg in data section (i presume)

How can i isolate "binary" datas only and by the way save file "icon.jpg" on my HD.

Thanks.
Sheeva700
Posts: 27
Joined: Sun Mar 22, 2015 8:24 pm

Re: Download Jpg file from HTTP (or binary)

Post by Sheeva700 »

DownloadFile() id the solution. :D
Post Reply