Existing PB ReceiveHTTPFile() is very useful but if we want parse downloaded file before writed to disk isn't possible. Now We must download file using ReceiveHTTPFile() , read whole file, parse it and then write it again to disk.
Something like Result$ = GetHTTPFile(URL$) or Result$ = ReceiveHTTPFileToMemory(URL$) is very useful in PureBasic Http commands.
Thanks
[Implemented] Result$ = GetHTTPFile(URL$)
Re: Result$ = GetHTTPFile(URL$)
+1
For general files, it would be better to load into a memory buffer and not into a String as Return,
because the file can be binary and may contain zeros so that would cut the string!
So, for Text-Files:
String.s = ReceiveHTTPString(URL.s)
My code here
for Binary-Files:
*Memory = ReceiveHTTPData(URL.s)
For general files, it would be better to load into a memory buffer and not into a String as Return,
because the file can be binary and may contain zeros so that would cut the string!
So, for Text-Files:
String.s = ReceiveHTTPString(URL.s)
My code here
for Binary-Files:
*Memory = ReceiveHTTPData(URL.s)
PB 6.01 ― Win 10, 21H2 ― Ryzen 9 3900X, 32 GB ― NVIDIA GeForce RTX 3080 ― Vivaldi 6.0 ― www.unionbytes.de
Lizard - Script language for symbolic calculations and more ― Typeface - Sprite-based font include/module
Lizard - Script language for symbolic calculations and more ― Typeface - Sprite-based font include/module
Re: Result$ = GetHTTPFile(URL$)
+1
I think something like this String.s = ReceiveHTTPString(URL.s) or this *Memory = ReceiveHTTPData(URL.s) is more useful of existing ReceiveHTTPFile() command.
I think something like this String.s = ReceiveHTTPString(URL.s) or this *Memory = ReceiveHTTPData(URL.s) is more useful of existing ReceiveHTTPFile() command.
Re: Result$ = GetHTTPFile(URL$)
I'm agree with you, now is very better for string and binary files.STARGÅTE wrote:+1
So, for Text-Files:
String.s = ReceiveHTTPString(URL.s)
for Binary-Files:
*Memory = ReceiveHTTPData(URL.s)
- DoubleDutch
- Addict
- Posts: 3220
- Joined: Thu Aug 07, 2003 7:01 pm
- Location: United Kingdom
- Contact:
Re: Result$ = GetHTTPFile(URL$)
+1, but I also think that the built-in http, mail and ftp libraries also need automatic and programmable proxy support - maybe a new library called 'proxy' to sort out these things for future commands?
https://deluxepixel.com <- My Business website
https://reportcomplete.com <- School end of term reports system
https://reportcomplete.com <- School end of term reports system
Re: Result$ = GetHTTPFile(URL$)
Yes, please add this along with:
- cookie support
- easy posting of variables to URL's using POST or GET
- cookie support
- easy posting of variables to URL's using POST or GET
A sketch tool with a twist, SECret INSPiration made using Purebasic.
Re: Result$ = GetHTTPFile(URL$)
Not any news in PB 4.60? Fred?
Re: Result$ = GetHTTPFile(URL$)
+1
I know this thread is old, but the request is still not implemented and it would be very helpful.
I know this thread is old, but the request is still not implemented and it would be very helpful.
PB 5.70 LTS (x64) - Debian Testing, Gnome 3.30.2
- majikeyric
- Enthusiast
- Posts: 187
- Joined: Mon Oct 21, 2013 5:21 pm
- Location: France
- Contact: