in reply to ftp a file

If the perl-script runs on the server you get to (ftp-) get it.

If the perl-script runs on your local machine you have to (ftp-) put it.