다음: Base64 and Binary Data Transmission, 이전: FTP Objects, 상위 문서: Networking Utilities [차례][찾아보기]
Download a remote file specified by its url and return its content in string s.
For example:
s = urlread ("ftp://ftp.octave.org/pub/README");
The variable success is 1 if the download was successful, otherwise it is 0 in which case message contains an error message.
If no output argument is specified and an error occurs, then the error is signaled through Octave’s error handling mechanism.
This function uses libcurl. Curl supports, among others, the HTTP, FTP, and FILE protocols. Username and password may be specified in the URL. For example:
s = urlread ("http://user:password@example.com/file.txt");
GET and POST requests can be specified by method and param. The parameter method is either ‘get’ or ‘post’ and param is a cell array of parameter and value pairs. For example:
s = urlread ("http://www.google.com/search", "get", {"query", "octave"});
같이 보기: urlwrite.
Download a remote file specified by its url and save it as localfile.
For example:
urlwrite ("ftp://ftp.octave.org/pub/README", "README.txt");
The full path of the downloaded file is returned in f.
The variable success is 1 if the download was successful, otherwise it is 0 in which case message contains an error message.
If no output argument is specified and an error occurs, then the error is signaled through Octave’s error handling mechanism.
This function uses libcurl. Curl supports, among others, the HTTP, FTP, and FILE protocols. Username and password may be specified in the URL, for example:
urlwrite ("http://username:password@example.com/file.txt", "file.txt");
GET and POST requests can be specified by method and param. The parameter method is either ‘get’ or ‘post’ and param is a cell array of parameter and value pairs. For example:
urlwrite ("http://www.google.com/search", "search.html", "get", {"query", "octave"});
같이 보기: urlread.
다음: Base64 and Binary Data Transmission, 이전: FTP Objects, 상위 문서: Networking Utilities [차례][찾아보기]