[ library(http_client) | Reference Manual | Alphabetic Index ]

http_open(+Url, -Stream)

Download a web document given its URL and open a Stream to read it
Url
A string
Stream
A variable or atom

Description

This utility downloads a web document (given its URL) into a string stream and returns that string stream's identifier for reading.

Examples

    [eclipse 1]: lib(http_client).
    yes.
    [eclipse 2]: http_open("http://icparc.ic.ac.uk/index.html",S),
                 read_string(S, end_of_line, _, L).
    S = 19
    L = "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 3.2//EN\">"
    yes.