mIRC Homepage
Posted By: HAMM3R simple ftp function - 26/09/06 06:59 PM
Hey i need a script that can login to a ftp server (uname and pw) and download a file, then delete it from that ftp server. Ive seen a few complicated ftp commands for mirc that dont seem to work. Im not very experienced with sockets. If anyone has something to do this, please let me know. Thanks

HAMM3R
Posted By: RusselB Re: simple ftp function - 26/09/06 09:01 PM
While this probably can be done, we would need more information to be able to write it. Minimum that I can think of, would be the ftp site address.
Since the ftp site requires a login, then it would be almost impossible to correctly test any code written, unless the person that wrote it had an account for that site. (while not impossible, I wouldn't want to bet on it).
Also, for the file transfer, you're not going to manage to get FTP speeds using mIRC.

Personally, I think you'd be just as well, if not better, off getting an FTP program and using it. Some FTP programs will allow you to delete files from the remote location, presuming you have sufficient access to the remote location.

For FTP, I use FlashFXP
Posted By: HAMM3R Re: simple ftp function - 26/09/06 09:23 PM
Yeah but all I need is to download a 1kb or 2kb text file, save it to a var or hash table, then delete it. It also needs to be able to download about once a second. Basically im exporting chat from a game server to echo.txt. I can access this from the ftp server. I want to connect, download echo.txt, msg it to a channel, then delete echo.txt and do it all again 1 second later. This way when i download a new echo.txt its only new text. So a ftp program just wouldnt work well here. Any ideas?
Posted By: RusselB Re: simple ftp function - 26/09/06 09:29 PM
Ideas, yes, but as I stated, I don't think anything could realistically be written without the ftp address as a minimum of information.
Posted By: MikeChat Re: simple ftp function - 26/09/06 09:59 PM
Quote:

Basically im exporting chat from a game server to echo.txt. I can access this from the ftp server. I want to connect, download echo.txt, msg it to a channel, then delete echo.txt and do it all again 1 second later.


and you want to do it this way because you are not using mIRC on the gamer server network?

otherwise there are pleanty of multiserver echobots, even on these boards
Posted By: Mpdreamz Re: simple ftp function - 27/09/06 08:23 AM
Windows 's ftp.exe can be scripted.
http://tinyapps.org/docs/ftp.html
Code:
//run -h ftp.exe -s:myscript
//run a timer checking if the file has downloaded.
© mIRC Discussion Forums