转载:https://www.jb51.net/article/62914.htm
转载:https://www.cnblogs.com/zakun/p/5387910.html
php连接sapwebservices接口
public function getwebservice($param){
$user = 'username';
$password = 'password';
$wsdl = '*****'; /*wsdl地址*/
$SOAP_CONFIG = array(
'login' => $user,
'password' => $password,
'trace' =>true,
'soap_version'=>SOAP_1_2,
'connection_timeout' => 50,
'encoding' => 'UTF-8',
'cache_wsdl' => WSDL_CACHE_NONE,
'keep_alive' => false
);
try {
$client = new \SoapClient($wsdl, $SOAP_CONFIG); //调用sap里的接口
/* $param= array(
'参数1' => '1',
'参数2' => '2',
'参数3' => '3',
'参数4' => '4');*/
$ve=$client->__call("ZSdSoInfo", array($param));
return $ve;
} catch (Exception $e) {
print $e->getMessage();
}
}
php链接.net接口
$ws = "http://*****?wsdl";//webservice服务的地址
$client = new SoapClient ($ws);
$result=$client->kelOtp(array('参数1'=>参数1,'参数2'=>参数2);
$a= $result->kelOtpResult;/
网友评论