Hello,
I am struggling with a strange problem. I have a script which makes a simple Soap request to my Magento API:
When I run this through a browser I get
However, when I run it from the command line it works fine:
It is the same lsphp5 binary that is configured in LiteSpeed LSAPI external app.
Any ideas? I am sort of out of ideas at the moment.
I am struggling with a strange problem. I have a script which makes a simple Soap request to my Magento API:
PHP:
try {
$proxy= new SoapClient($host.'/index.php/api/soap/?wsdl',array('exceptions' => 1,'trace' => 1,"connection_timeout" => 120));
$sessionId= $proxy->login($apiuser, $apikey);
echo "Magento Api accessed Successfully.";
echo "<br>Session Id is:". $sessionId;
} catch (Exception $e) {
echo "==> Error: ".$e->getMessage();
}
Code:
SOAP-ERROR: Parsing WSDL: "Couldn't load from 'http://....../index.php/api/soap/index/wsdl/1/' : failed to load external entity "http://..../index.php/api/soap/index/wsdl/1/"
Code:
/usr/local/lsws/fcgi-bin/lsphp5 path_to_script
Magento Api accessed Successfully.<br>Session Id is: xxxx
Any ideas? I am sort of out of ideas at the moment.
Last edited by a moderator: