This script can be used from the command line as a ‘no questions asked’ method of uploading one or many files with a single command. Additionally, you can call this script from batch files to perform automated file uploads. A few uses for this include (but, of course, not limited to):

Include in backup scripts to send data offsite. Upload html/php/etc. files to a web server with a single command. Create shortcuts to send a common group of files (such as a web site’s source pages).

Configuration

The only configuration required is to set the FTP server connection information. Under the “Connection information” line, set the following:

Server – The FTP Server you are uploading to. You can either enter the DNS name (ftp. myserver. com) or IP address (1. 2. 3. 4). UserName – Your user name for connecting to FTP server. Password – Your password for connecting to the FTP server.

Depending on your firewall settings, the first time you run this script you may be prompted to allow FTP to connect to the Internet. Setting this to never prompt you again should remove future warnings.

The Script

Download Upload to FTP Script from Sysadmin Geek