Non-WSDL mode

[email protected] (Dani Castaños)
Newsgroups php.soap
Message-ID <[email protected]>
Hi all!

I have a little problem with Non WSDL Mode. I define classes for my 
complex types, but server seems to not recognize them.
My code:

soap_server.php
==============


/*-----------FUNCTIONS----------*/
**
 * Method to create an event subscriber
 *
 * @param SubscriberData $subscriber
 * @return unknown
 */
function CreateSubscriber( $subscriber )
{
}//function CreateSubscriber( $name )


/*------------CLASSES---------*/

class SubscriberData
{
  public $id;
  public $name;
 
}//class SubscriberData


/*----------------MAIN-----------------*/

$classmap = array('SubscriberData' => 'SubscriberData');
$server   = new SoapServer( null, array( 'uri' => 
'http://localhost/poc/', 'classmap' => $classmap ) );

$server->addFunction( 'CreateSubscriber' );

$server->handle( $GLOBALS['HTTP_RAW_POST_DATA'] );


REQUEST
=======

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope 
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" 
xmlns:ns1="http://localhost/poc/" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
xmlns:ns2="http://xml.apache.org/xml-soap" 
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" 
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:Body><ns1:CreateSubscriber><param0 
xsi:type="ns2:Map"><item><key xsi:type="xsd:string">name</key><value 
xsi:type="xsd:string">Dani</value></item></param0></ns1:CreateSubscriber></SOAP-ENV:Body></SOAP-ENV:Envelope>

As you can see, Subscriberdata class is not recognized. It is something 
missing in my server constructor??

Thank you in advance!
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.