title: Help with NuSoap - Creation of web service
body: <p>I have been helplessly trying to create a web service in PHP using NuSoap for the past 2 days. However, after endlessly sifting through various tutorials and guides, i am still stuck with <strong>10 lines of code that refuse to work.</strong></p>
  
  <p>Server :</p>
  
  <pre><code>// Pull in the NuSOAP code
  require_once('./lib/nusoap.php');
  
  // Create the server instance
  $server = new soap_server;
  
  // Initialize WSDL support
  $server-&gt;configureWSDL('hellowsdl','http://mysite.com');
  
  // Register the method to expose
  $server-&gt;register('hello',
      array("params"=&gt;"xsd:string"),
      array("result"=&gt;"xsd:string"),
      'http://mysite.com'
  );
  
  // Define the method as a PHP function
  function hello($name) {
          return 'Hello, ' . $name;
  }
  
  // Use the request to (try to) invoke the service
  $HTTP_RAW_POST_DATA = isset($HTTP_RAW_POST_DATA) ? $HTTP_RAW_POST_DATA : '';
  $server-&gt;service($HTTP_RAW_POST_DATA);
  </code></pre>
  
  <p>And the Client :</p>
  
  <pre><code>// Pull in the NuSOAP code
  require_once('./lib/nusoap.php');
  
  // Create the client instance
  $client = new nusoap_client('http://localhost/nusoap/server.php?wsdl',true);
  
  // Call the SOAP method
  $result = $client-&gt;call('hello',array("name"=&gt;"Scott"));
  
  var_dump($result);
  </code></pre>
  
  <p>Gives me a bool(false)</p>
  
  <p>Where am i going wrong ???</p>