hi again,
I just installed cURL and recompiled PHP to use it. What I need is send a POST request from my Server, to another one.
When I use this code it works perfectly:
<?
$ch = curl_init ("http://www.server.com");
curl_setopt ($ch, CURLOPT_POST, 1);
curl_setopt ($ch, CURLOPT_POSTFIELDS, "foo=one&bar=two");
curl_exec ($ch);
curl_close ($ch);
?>
But when I try to send it via SSL like this:
<?
$ch = curl_init ("https://www.server.com");
curl_setopt ($ch, CURLOPT_POST, 1);
curl_setopt ($ch, CURLOPT_POSTFIELDS, "foo=one&bar=two");
curl_exec ($ch);
curl_close ($ch);
?>
then it fails without giving an error or anything. Apache's error_log is empty as well.
PHP (4.0.6) is compiled like this:
./configure
--with-apache=../apache_1.3.20
--with-mysql=/usr/local/mysql
--with-gd=../gd-1.8.3
--with-jpeg-dir=../jpeg-6b
--with-zlib
--with-openssl=/usr/local/openssl
--with-curl=/usr/local/curl
--enable-track-vars
The receiving server supports SSL.
What's wrong? Do I need mod_ssl on my Apache as well? Am I missing a curlopt?
Thanks in advance,
Dominique