1.

Solve : auto up ftp?

Answer»

hi there,

I would like to know if it's possible to upload an index.html file to my ftp server automatically.

I'm ASSuming i'd need some sort of .bat file

would anybody be able to write a batch file (ftp.servername.com: - user name: - password:) to auto upload files to ftp please, Actually i would like it to auto update every...say.... 2 hours?, if possible

living in hope.

Lionel
see this code i hope its useful

PUT these ftp commands inside a file for eg a2.
assuming UR destination server IP is 192.168.2.1

open 192.168.2.1
USERNAME
password
ascii
cd "specified directory u want to sent the files to"
mput *.htm
bye

then inside a bat file do this

ftp -i -s:.\a2 >>ftplog.txt

put the two files to gether in the same directory where u put the html files u want to ftp them
and when u put the username and password make sure that u have no spaces after them unless they include a one

and to make it auto u have to put the bat file in the windows Scheduled Taskshi .bat_man

lol love the NICK, very apt

thanks for the reply, now.......

the code file is a *.txt file right?

i can create a .bat file by creating a .txt file, type in the code, then, change extension from .txt to .bat, right?

i'm hopeless at this stuff, is there a timer there somewhere, ...say .. to auto ftp up files every 30 minutes?

lionel thats right u just write the code and then change the extension
now if u want to make it work every 30 minute then the best way is to use windows Scheduled Tasks its very easy to use it. U can find it in control panel


and don't be depressed there always a solution for any problem
and the more problems u face the more experience u get

i hope its useful for u yes thanks

BUT, now the added problem overwriting the file already sitting in my server, btw: it's an updates channel STATS html file



Discussion

No Comment Found