Automatic uploading of files to my web page

I thought that I might relate some of my experience with the automatic uploading of files (images) on my systems.  On my systems, the weather data and POES images are uploaded via their respective programs (WXtoImg and Weather Display) Image files for my seismometer, geiger counter and LRIT images are created on the computers capturing the data, but there is no function in the respective programs for uploading.  For these programs, the images are written to a particular directory while awaiting for subsequent uploading to the webpages.  Here is the problem : A file should be uploaded whenever it has been a replaced with a newer one.  But, I don’t want to upload an directory whenever there has been a single replaced file…I really only want to upload the updated one(s) to conserve bandwidth.

The solution that I came up with is not elegant, but it works. I think that it would have been easier if I was working with Linux, but I’m stuck with windows for now.  I have seen some shareware and commercial software to do this…but I try to be frugal and conserve money where I can.

I currently use two different programs for the task.  One is called Watch4Folder.  This particular program watches a particular directory on my computer for any changes in the files there.  Once a change is noted, something can happen, and in my case, a batch file is then run.  The batch file calles a second program called WinSCP.  (I use version 4.3.7 as I havn’t upgraded to the later releases yet.  Also, I happen to use the portable version)  WinSCP has the nice feature of directory synchronization, which allows the program to connect to my webpage, compare a specific directory on my computer to a directory on my server, and only upload the changed files, again, to conserve bandwidth.

Some have suggested that I might use a .bat file to do this.  Unfortunately, I am not well enough versed in DOS bat files to figure out how to do this.  Maybe a .bat file could do this, but some of the complications are that 1, 2, 5, or all the files might have changed, and being able to account for that is just too complex for me.

If anyone knows of better solutions, please write a comment or drop me a line.


Leave a Reply