'.$err.''; // At this point, you know the call that follows will fail } $response = []; if (!empty($function)) { $response = $client->call($function); echo '
'; print_r($response); echo '#'; } else { echo "empty function $function"; } $list = scandir($serversys); $scripts = []; foreach ($list as $item) { if (substr($item, 0, 1) == '.') { continue; } if (substr($item, -8) == 'soap.php') { $scripts[] = $item; } } ?>