(PHP 5, PHP 7, PHP 8)
SoapHeader::__construct — Constructeur SoapHeader
$namespace,$name,$data = ?,$mustunderstand = ?,$actor = ?Construit un nouvel objet SoapHeader.
namespacele namespace de l'élément d'en-tête SOAP.
nameLe nom de l'élément d'en-tête SOAP.
dataUn contenu de l'en-tête SOAP. Il peut être une valeur PHP ou un objet SoapVar.
mustUnderstand
Valeur de l'attribut mustUnderstand
de l'élément d'en-tête SOAP.
actor
Valeur de l'attribut actor
de l'élément d'en-tête SOAP.
Exemple #1 Exemple avec SoapHeader::__construct()
<?php
$client = new SoapClient(null, array('location' => "http://localhost/soap.php",
'uri' => "http://test-uri/"));
$client->__soapCall("echoVoid", null, null,
new SoapHeader('http://soapinterop.org/echoheader/',
'echoMeStringRequest',
'hello world'));
?>