Sack https://github.com/pereckerdal/sack provides a very nice HTTP client library. For credits and license see source files.
It's written atop BH, and can easily be exploded out to be run atop load/include.
There is one or two updates to the HTTP client functionality in the attached version that are not committed to the github repo yet. To our knowledge it works perfectly. Currently non-HTTP compliant server response may cause an internal exception.
Thanks, Mikael
2011/9/12 Alex Queiroz asandroq@gmail.com
Hallo,
On Fri, Sep 9, 2011 at 6:28 PM, Steve Graham jsgrahamus@yahoo.com wrote:
Although I have programmed for decades, I am new to Scheme/Gambit. I thought that I would use a project I've been contemplating as a help in learning the language. There is a website of scriptures which I wish to download. Some of the webpages, of course, are indices into books and then chapters. So I
would
need to follow the links until I got to the actual text, which I would
then
file into a database by volume, book, chapter and verse. I would appreciate any hints as to how to do this. I'm thinking I would need some help with downloading web pages, stripping HTML and saving to a database.
For downloading the page Gambit already gives you TCP sockets but you would have to write the code for HTTP GET, which is not complex. For parsing the HTML you will need SSAX[1], there is a "package" for it in the Dumping Grounds[2]. Also in the Dumping Grounds you will find several database interfaces.
[1] - http://ssax.sourceforge.net/ [2] - http://dynamo.iro.umontreal.ca/~gambit/wiki/index.php/Dumping_Grounds
Cheers,
-alex http://www.artisancoder.com/ _______________________________________________ Gambit-list mailing list Gambit-list@iro.umontreal.ca https://webmail.iro.umontreal.ca/mailman/listinfo/gambit-list
Afficher les réponses par date
The online repo has been updated with the changes included in the previous email.
2011/9/12 Mikael
Sack https://github.com/pereckerdal/sack provides a very nice HTTP client library.
..
There is one or two updates to the HTTP client functionality in the attached version that are not committed to the github repo yet. To our knowledge it works perfectly. Currently non-HTTP compliant server response may cause an internal exception.