I have a very strange curl problem, when I send a request to my Apache Apache Ubuntu server, the apache server freezes, if I debug my PHP code, I see that
$fp = curl_exec($ch);
Never comes back. I think the actual post request is correct, because I can successfully execute the same POST request with the postman.
Below are my curling options:
$ch = curl_init();
curl_setopt($ch,CURLOPT_SSL_VERIFYPEER , 0);
curl_setopt($ch,CURLOPT_URL, $this->url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch,CURLOPT_POST,true);
curl_setopt($ch,CURLOPT_HTTPHEADER,$testHeader);
curl_setopt($ch,CURLOPT_POSTFIELDS,$post_data);
$fp = curl_exec($ch);
One strange thing: if im quick and restart my apache server
sudo service apache reload
while in this hanged state, curl_exec returns immediately, and I get my data. I am not a real web developer and more a guy from the windows, so any help would be greatly appreciated. :)
UPDATE
Curl, . , . Apache, , . CURLOPT_VERBOSE.
2:
. , , . , - . .