Best unofficial Apache Server developers community |
|
I'm trying to upload a file to a remote FTP server (which requires FTPES) using PHP. The script I've written works locally, but on the live server ftp_login() returns false and the following warnings appear in the error log:
I know that the login details are correct (since identical code works locally). I can successfully connect to the FTP server from the live server using curl on the command line. The server is running PHP 5.3.3 (Zend Server on CentOS). I can see from phpinfo that the PHP configure command includes -with-openssl=/usr/local/openssl-0.9.8o The code is simply this:
For reference my local box (where this works fine) is running PHP 5.3.3-1ubuntu9.3. Can anyone point me in the right direction?
posted via StackOverflow
|
|
 
|
I eventually solved this problem by changing the code to use the PHP cURL functions instead, since I knew I could connect okay from the command line with that. There probably is way to get this working with the FTP functions, but in case this helps anyone else here's my working cURL version:
|