Sfairadora

  • Reference Guide

open_url

f <- open_url(url)
f <- open_url(url, user_name)
f <- open_url(url, user_name, password)
The parameter f is a variable of the type File. The function opens the internet resource specified by the parameter url. If needed, a user_name and password can be specified. All the parameters are of the type String.

Return Value

An l-value referring to the variable f is returned. If an error occurs, an Error value is returned.

Examples

Reading an image from the internet:
var File f;
f <- open_url( "http://upload.wikimedia.org/wikipedia/commons/d/d4/Hradschin_Prag.jpg");
var Bitmap bmp = read_binary(f, Bitmap);
Reading a web page:
var File f;
f <- open_url("http://www.wikipedia.org");
var Text web = read_text(f);

See Also