update ftp.php

Added setPassiveMode for changing FTP passive mode to on or off. In passive mode, data connections are initiated by the client, rather than by the server. It may be needed if the client is behind firewall.
Added exception to getConnection method when connection to FTP server fails.