--- /dev/null
+<?xml version ='1.0' encoding ='UTF-8' ?>
+ <definitions name='User'
+ targetNamespace='http://example.org/User'
+ xmlns:tns=' http://example.org/User '
+ xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/'
+ xmlns:xsd='http://www.w3.org/2001/XMLSchema'
+ xmlns:soapenc='http://schemas.xmlsoap.org/soap/encoding/'
+ xmlns:wsdl='http://schemas.xmlsoap.org/wsdl/'
+ xmlns='http://schemas.xmlsoap.org/wsdl/'>
+
+ <types>
+ <xsd:schema
+ targetNamespace="http://example.org/User"
+ xmlns="http://www.w3.org/2001/XMLSchema">
+ <xsd:complexType name="user">
+ </xsd:complexType>
+ </xsd:schema>
+ </types>
+
+
+ <message name='getusersRequest'>
+ <part name='search' type='xsd:string'/>
+ </message>
+ <message name='getusersResponse'>
+ <part name='user' type='xsd:user'/>
+ </message>
+
+ <portType name='UserPortType'>
+ <operation name='tmp_get_users'>
+ <input message='tns:getusersRequest'/>
+ <output message='tns:getusersResponse'/>
+ </operation>
+ </portType>
+
+ <binding name='UserBinding' type='tns:UserPortType'>
+ <soap:binding style='rpc'
+ transport='http://schemas.xmlsoap.org/soap/http'/>
+ <operation name='tmp_get_users'>
+ <soap:operation soapAction='urn:xmethods-delayed-quotes#tmp_get_users'/>
+ <input>
+ <soap:body use='encoded' namespace='urn:xmethods-delayed-quotes'
+ encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'/>
+ </input>
+ <output>
+ <soap:body use='encoded' namespace='urn:xmethods-delayed-quotes'
+ encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'/>
+ </output>
+ </operation>
+ </binding>
+
+ <service name='UserService'>
+ <port name='UserPort' binding='UserBinding'>
+ <soap:address location='http://jerome.moodle.com/Moodle_HEAD/moodle/webservice/soap/server.php?classpath=user'/>
+ </port>
+ </service>
+ </definitions>
\ No newline at end of file
--- /dev/null
+<?php
+/**
+ * Main script - SOAP server
+ *
+ * @author Jerome Mouneyrac <jerome@moodle.com>
+ * @version 1.0
+ * @package webservices
+ */
+
+/*
+ * SOAP server
+ */
+require_once(dirname(__FILE__) . '/../../config.php');
+
+//retrieve the api name
+$classpath = optional_param(classpath,null,PARAM_ALPHA);
+require_once(dirname(__FILE__) . '/../../'.$classpath.'/wsapi.php');
+
+/// run the server
+$server = new SoapServer("moodle.wsdl");
+$server->setClass($classpath."_ws_api");
+$server->handle();
+
+?>
\ No newline at end of file
--- /dev/null
+<?php
+
+/**
+ * Main script - try a SOAP connection
+ *
+ * @author Jerome Mouneyrac <jerome@moodle.com>
+ * @version 1.0
+ * @package webservices
+ */
+
+/*
+ * SOAP client
+ */
+require_once(dirname(__FILE__) . '/../../../config.php');
+
+//$client = new SoapClient("moodle.wsdl");
+
+$client = new SoapClient("../moodle.wsdl",array(
+ "trace" => 1,
+ "exceptions" => 0));
+
+try {
+ var_dump($client->tmp_get_users("admin"));
+ printLastRequestResponse($client);
+} catch (SoapFault $exception) {
+ echo $exception;
+}
+
+
+function printLastRequestResponse($client) {
+ print "<pre>\n";
+ print "Request :\n".htmlspecialchars($client->__getLastRequest()) ."\n";
+ print "Response:\n".htmlspecialchars($client->__getLastResponse())."\n";
+ print "</pre>";
+}
+
+?>
\ No newline at end of file