Click here to Skip to main content
15,946,316 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi Guys,
I am trying to call a web service using php,
I am wrestling two days with an issue, searching on the internet didn't help, I have tried to run simillar examples but I receice an empty browser (without any errors but still with no content)

I am using wamp server and my php code is very simple
PERL
<pre><?php

  try {
            $wsdl_url = "http://**********file?WSDL";
            $client = new SOAPClient($wsdl_url);
            $param = array(
                'Name' => "Greece",
            );
            $return = $client->GetCitiesByCountry($param);
    var_dump($return);
            print_r(array_values($return));
            echo $return;
           
        } catch (Exception $e) {
            echo "Exception occured: " . $e;
        }

?>


when I run it I receive an empty browser and nothing else (no errors, nothing) if I writte any other php code it runs properly.

Please i will be greatfull for any help or advise!!

Thank all of you for your time,
Friendly,
Jason

What I have tried:

I tried to and as following but still nothing (in visual studio at C# I run it and worked properly but in php not)

PHP
$wsdl_url = "http://**********file?WSDL";
            $client = new SOAPClient($wsdl_url);
            $param = array(
                'Name' => "Greece",
            );
            $return = $client->GetCitiesByCountry($param);
    var_dump($return);
            print_r(array_values($return));
            echo $return;
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900