# HG changeset patch # User Rik # Date 1674749933 28800 # Node ID 713de911848f44dcd589748767c589538840d271 # Parent e995783d78e745d4be775b0246606a2ff8e94bac doc: Fix example URLs in urlread, urlwrite to work. * urlwrite.cc (Furlread, Furlwrite): Replace URL references to "ftp://ftp.octave.org" to "http://ftp.octave.org" because server no longer accepts ftp protocol. Re-write awkward sentence construction that required capitalizing "Curl" when referring to "curl" library. diff -r e995783d78e7 -r 713de911848f libinterp/corefcn/urlwrite.cc --- a/libinterp/corefcn/urlwrite.cc Wed Jan 25 15:28:40 2023 -0500 +++ b/libinterp/corefcn/urlwrite.cc Thu Jan 26 08:18:53 2023 -0800 @@ -67,7 +67,7 @@ @example @group -urlwrite ("ftp://ftp.octave.org/pub/README", +urlwrite ("http://ftp.octave.org/pub/README", "README.txt"); @end group @end example @@ -80,9 +80,9 @@ 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: +This function uses libcurl. The curl library supports, among others, the HTTP, +FTP, and FILE protocols. Username and password may be specified in the URL, +for example: @example @group @@ -188,7 +188,7 @@ For example: @example -s = urlread ("ftp://ftp.octave.org/pub/README"); +s = urlread ("http://ftp.octave.org/pub/README"); @end example The variable @var{success} is 1 if the download was successful, @@ -198,9 +198,9 @@ 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: +This function uses libcurl. The curl library supports, among others, the HTTP, +FTP, and FILE protocols. Username and password may be specified in the URL@. +For example: @example s = urlread ("http://user:password@@example.com/file.txt"); @@ -213,8 +213,8 @@ @example @group -s = urlread ("http://www.google.com/search", "get", - @{"query", "octave"@}); +s = urlread ("http://www.google.com/search", + "get", @{"query", "octave"@}); @end group @end example @seealso{urlwrite}