Zend_Rest_Client Error on localhost
I'm using Zend_Rest_Client to connect Zend_Rest_Server, everything seems to be fine, but when I try to get () from the server, I get this error:
Zend_Http_Client_Adapter_Exception: Failed to connect to TCP: // local: 80. Error # 10060: A connection attempt failed because the related party did not respond properly after a period of time, or the established connection failed because the connected host was unable to respond. in C: \ WWW \ zf_1_72 \ libraries \ Zend \ Http \ Client \ adapter \ Socket.php on line 148
here is the code i am using
$client = new Zend_Rest_Client('http://localhost/my_application/api/index/');
$client->auth($key);
$result = $client->get();
thank for any advice
+1
source to share
1 answer
This thread recommends that the problem might be with the name "localhost" - use instead 127.0.0.1
.
+3
source to share