刘桂岩 3 vuotta sitten
vanhempi
commit
32cca924e2
1 muutettua tiedostoa jossa 5 lisäystä ja 1 poistoa
  1. 5 1
      app/controller/Index.php

+ 5 - 1
app/controller/Index.php

@@ -35,7 +35,11 @@ class Index extends BaseController
 //            array(
 //                'stream_context'    => $streamContext
 //            ));
-        $client = new \SoapClient("http://112.103.134.89:10020/server.php?wsdl");
+//        $client = new \SoapClient("http://112.103.134.89:10020/server.php?wsdl");
+        use_soap_error_handler(false);
+        $requestUrl = "http://112.103.134.89:10020/server.php?wsdl";
+        $options = array("trace" => 1, "cache_wsdl" => WSDL_CACHE_NONE,"exception" => 0,'location'=>'http://112.103.134.89:10020/server.php?wsdl','uri'=>'http://tempuri.org/');
+        $client = new SoapClient($requestUrl, $options);
         $data = [
             'Barcode'=>'12203310010001'
         ];   //请求参数