Uncaught SoapFault exception: [HTTP] Error Fetching http headers Uncaught SoapFault exception: [HTTP] Error Fetching http headers php php

Uncaught SoapFault exception: [HTTP] Error Fetching http headers


Try to set :

default_socket_timeout = 120

in your php.ini file.


Did you try adding

'trace'=>1,

to SoapClient creation parameters and then:

var_dump($client->__getLastRequest());var_dump($client->__getLastResponse());

to see what is going on?


This error can appear on the client if there is a problem on the server side. For example, if the SOAP server is a PHP script with a parse error, the client will fail with this message.

If you are in control of the server, tail your Apache error_log on the machine that hosts the SOAP server. On CentOS you will find this in /var/log/httpd/error_log, so the command is:

tail -f /var/log/httpd/error_log

Now refresh the client and watch for the error message. Any PHP errors with the server script will be shown.

Hope that helps someone.