3v4l.org

run code in 300+ PHP versions simultaneously
<?php class SoapService { const WSDL_URL = 'https://soap.cap.co.uk/Vehicles/CapVehicles.asmx?WSDL'; private $client; function __construct() { $this->client = new SoapClient(self::WSDL_URL, array("trace" => 1, "exception" => 0)); } function getMakes() { $header = NULL; $result = $this->client->__soapCall("GetCapMan", array( "GetCapMan" => array( "subscriberId" => 'xxxx', "password" => "xxxx", "database" => "car", "justCurrentManufacturers" => true, "bodyStyleFilter" => '' ) ), NULL, $header); return $result; } } $client = new SoapService(); $makes = $client->getMakes(); var_dump($makes);

preferences:
66.21 ms | 402 KiB | 5 Q