SoapClient::SoapClient
(no version information, might be only in CVS)
SoapClient::SoapClient --
Constructeur SoapClient
Description
object
SoapClient::SoapClient ( mixed wsdl [, array options])
SoapClient::SoapClient() permet la création
d'objets SoapClient en mode WSDL ou non-WSDL.
Dans le premier cas, wsdl doit être
l'URI d'un fichier fichier WSDL, et options doit
être un tableau.
Dans le second cas, wsdl doit valoir NULL et les
options location et uri doivent être fournies :
location est l'URL d'action et uri
est l'espace de nommage du service SOAP.
Les options style et use ne fonctionnent
qu'en mode non-WSDL. En mode WSDL, elles sont dans le fichier WSDL.
L'option soap_version spécifie si on utilise
SOAP 1.1, ou le client SOAP 1.2.
Dans le cas de l'identification HTTP, vous devez utiliser les options
login et password. Pour une
connexion HTTP via un serveur proxy, utilisez les options
proxy_host, proxy_port,
proxy_login et proxy_password.
Exemple 1. Exemple avec SoapClient::SoapClient()
<?php
$client = new SoapClient("some.wsdl");
$client = new SoapClient("some.wsdl", array('soap_version' => SOAP_1_2));
$client = new SoapClient("some.wsdl", array('login' => "some_name", 'password' => "some_password"));
$client = new SoapClient("some.wsdl", array('proxy_host' => "localhost", 'proxy_port' => 8080));
$client = new SoapClient("some.wsdl", array('proxy_host' => "localhost", 'proxy_port' => 8080, 'proxy_login' => "some_name", 'proxy_password' => "some_password"));
$client = new SoapClient(null, array('location' => "http://localhost/soap.php", 'uri' => "http://test-uri/"));
$client = new SoapClient(null, array('location' => "http://localhost/soap.php", 'uri' => "http://test-uri/", 'style' => SOAP_DOCUMENT, 'use' => SOAP_LITERAL));
?>
|
|