Closed Thread
Results 1 to 3 of 3

Thread: No wput?

  1. #1
    Wanch Guest

    No wput?

    It is nice to use 'wget' when fetching something but what if I want to 'put' something on an FTP server? There is no wput command that I can see.

  2. CODECALL Circuit advertisement

     
  3. #2
    Jordan Guest
    There is a wput project but I haven't tried it. http://wput.sourceforge.net/

    I generally just write shell scripts to do this. It is fairly easy.

    Code:
    #!/bin/sh -vx
    
    # Script to FTP data to server
    
    # Paramters:    host            FTP Server
    #               user            FTP Username
    #               passwd          FTP Password
    #               file            File to send/put
    ############################################################################
    
    # Variables
    HOST     =$1
    USER     =$2
    PASSWD=$3
    FILE      =$4
    
    # Connect to FTP HOST and Send File
    ftp -n $HOST <<END_SCRIPT
    quote USER $USER
    quote PASS $PASSWD
    put $FILE
    quit
    END_SCRIPT
    exit 0

  4. #3
    Tor
    Tor is offline Programming Expert
    Join Date
    Oct 2007
    Posts
    488
    Rep Power
    0
    Nice script! Seems odd there is no "wput" since there seems to be everything and everythings opposite in Linux command.

Closed Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts