  ftp Library Package 2.1 for Tcl/Tk Manual Pages

  COMMAND
    ftp::Put handle (local | -data "data") ?remote?
    The ftp::Put command stores a local file local to a remote file remote on the ftp server. The file parameters passed must contain a fully qualified path name, otherwise the command uses the current directory. If '-data "data"' is specified, then rather than transferring a file, the data passed in is used as the data to transfer. If remote file name is unspecified, the local file name is assigned to the remote file name.

    If the file was successfully transferred, then the command returns 1, if it fails 0.

  EXAMPLE

        # store unique file name
        ftp::Put $conn index.htm

        # store different file names
        ftp::Put $conn test.htm index.htm

        # with different fully qualified path name
        ftp::Put $conn /usr/local/src/my.tar.gz /incoming/foo.tar.gz

[Contents] [Previous: ftp::Rename] [Next: ftp::Append]

© 1999 Steffen Traeger