getting files off ftp connection
Question
I have been given a project where i need to write a program which runs on a server. This program needs to open an ftp connection to another server and pick up a file and place it in a given folder.
I dont know where to start although i think i need some sort of socket prgramming... can anyone help me with where to start ? what language or wat ? C++ of java is prefered...
I dont need a GUI just somethign executable so shell scripting or command line or even a desktop application
Solution
With Java, I would start from Apache Commons FTPClient.
With Python, I would start form ftplib.
With C++, you may find the answer here on SO.
OTHER TIPS
If Java is available, ftp4j may be a good choice.
http://www.sauronsoftware.it/projects/ftp4j/
This should help for Java: Apache commons net
You need explain more about in order to get a clear answer
What kind of application you want to run on your server (web application, desktop application-- command-line or with graphical user-interface)?
Although I dont know whether it fits your problem, I would recommended Qt framework for C++ which have a nice class QFTP, checkout it example
http://doc.qt.nokia.com/latest/network-qftp.html
notice that Qt is a heavy weight framework
Is fetching the file the only thing that the program does? If so, I wouldn't write a program at all, but use an existing one instead. Try wget
or curl
.