安裝 wsdl2phpgenerator
使用 composer 套件,其實安裝一點困難都沒有
composer require wsdl2phpgenerator/wsdl2phpgenerator
composer require wsdl2phpgenerator/wsdl2phpgenerator
<?php require 'vendor\autoload.php'; $generator = new \Wsdl2PhpGenerator\Generator(); $generator->generate( new \Wsdl2PhpGenerator\Config(array( 'inputFile' => 'http://www.cpami.gov.tw/opendata/wsdl/fd2_wsdl.xml', 'outputDir' => 'output' )) );