400 028 6601

建站动态

根据您的个性需求进行定制 先人一步 抢占小程序红利时代

phptrycatch异常处理结构

try{
   // if(!empty($UserCode)){
   $url= '';
   $client=new\SoapClient($url);
   $userLogin=new\stdClass();

   $userLogin->UserCode=$UserCode;
   $userLogin->ExpirDate=2;

   $loginResponse=$client->__call("GetToken",array(
       $userLogin
   ));
   $token=$loginResponse->GetTokenResult;
}catch(\Exception$e) {  //千万要注意这里的 \  很重要!!!否则不执行这里来
   $token='';
}

当前标题:phptrycatch异常处理结构
本文来源:http://mbwzsj.com/article/ppsiej.html

其他资讯

让你的专属顾问为你服务