I am running Apache 2.2.13 and PHP 5.2.12. Just installed PHP 5.2.12 manually (to access all the extensions) and enabled OpenSSL. phpinfo () indicates that OpenSSL is enabled and running OpenSSL 0.9.8k on March 25, 2009.
I get this error: PHP Fatal error: function call undefined ftp_ssl_connect ().
I saw where in the PHP manual it says "ftp_ssl_connect () is only available if both the ftp module and OpenSSL support are built in statically in php" and further states that "you must compile your own PHP binaries "to make it work with Windows.
I have a suspicion that phpinfo () only indicates OpenSSL as "enabled" because I uncommented the line "extension = php_openssl.dll" and have the correct DLLs in the right folders and the right path in the environment variables. And perhaps static build in PHP should be done regardless of what phpinfo () points to.
I believe that the purpose of distribution (as described above) is for dynamic extensions, but recompilation (for OpenSSL) is encoding a static extension.
The ftp extension works fine (built-in to PHP 5.2). I am testing this with the following code:
$ conn_id = ftp_connect ($ url); $ login_result = ftp_login ($ conn_id, $ username, $ password); ftp_close ($ conn_id);
Please note that to check ssl I change ftp_connect to ftp_ssl_connect. On reaching this line, I get the PHP error above in my Apache error log file.
mitch source share