PHP FTP Synchronizer - Free Program For Website Update

(c) 2007-2008 Kim Haskell. GNU GPL 2 License.

Free program to update your website from local files. PHP FTP Synchronizer traverses the tree structure of the source directory recursively and updates the file on the website, by replacing the files which were modified.

Why to use PHP FTP Synchronizer?

Compared to the various existing programs, commercial for the majority, the synchronizer offers speed options:
- Possible use of a backup version on which the comparisons are performed, what avoids downloading the remote file and allows an extremely fast update thus. Moreover that builds a second backup of the site, possibly on a removable storage unit.
- Possibility of uploading all files modified in n last days, n being a number of days that you define.
Moreover the executable program is a PHP script, it thus works on all operating systems, Windows, Linux, Mac... And you can extend its possibilities if needed.

Technical aspects

PHP FTP Synchronizer is a script whose source code is in Scriptol language and converted into PHP by the Scriptol PHP compiler available on this site, in version 7.0.
It work at command line (a graphic interface is under development for Windows).

How the program works

The required parameters being given (see below), the program has the location of your files, the name of the site (in ftp.xxxx.tld form), login and password, directory on hosting if one does not copy at root, as well as chosen options.
It reads each file by scanning in a recursive way the source directory and the sub-directories, compares files with remote files if there exists, and copies them or replaces them.
If the option of acceleration is selected, it compares the dates or contents of file with the backup, and if they are different uploads the files, copies them on the backup also and synchronizes the date of files in the backup with that of sources.

How PHP FTP Synchronizer is used

One opens a DOS Windows or a console under Linux or Mac.
One type a command in the form:

solp ftpsync [options]

or directly in PHP:

php ftpsync.php [options]

Example:

php ftpsync.php -v -llogin -pmotdepass -fftp.scriptol.com -dw:\scriptol\ -bf:\scriptol\ -wwww.scriptol.com

The options which are detailed in the handbook allow to pass all the required parameters. If a parameter misses, the program prompt you for it. But if an option is given and that must be followed by a string, this one must be provided in order, it is not asked by the program which in this case displays an error.

Documentation

Manual of use

Manual of PHP FTP Synchronizer in HTML version.
More formats are available, see at bottom.

Last changes in versions

Troubleshootings

It is possible also that the server closes the connection if it works for a long time. Use a backup directory or the -n option preferably.

Obtaining the program

The archive contains:
- The Scriptol source.
- The PHP executable script,
- The manual in HTML format, and ODF, you can create a PDF or Word's DOC file with Star Office (free).
- The ftpcheck script to verify a connection.
- The GPL licence.



Scriptol.com - haskell@scriptol.com