Re: Accessing SOAP Headers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

> Server PHP Code:
> 
> function requiredHeader($h) {
>   // do something with the header
>   // store result in $GLOBALS array
> }
> 
> function echoHeader() {
>   // pull result from $GLOABLS array
> }
> 
> $s = new SOAPServer('my.wsdl');
> $s->addFunction('requiredHeader');
> $s->addFunction('echoHeader');
> $s->handle();

I spotted this code before but it just confused me. Does this mean I
actually need to call the "requiredHeader" function from the soap client
in order to tell the server to read the header?

I was hoping for something more along the lines where if the server
receives a SOAP message with a header it was automatically extracted. So
if I called a "ApplicationRequest($appid)" from the client the
ApplicationRequest function on the server would have access
automatically to whatever headers were supplied in the request.

So far all the PHP soap I've done has been pretty easy and straight
forward, I was hoping the headers would be no different. Is there
something I'm missing here in my understanding of the situation?

Cheers,

Alex

-- 
PHP Soap Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Kernel Newbies]     [PHP Database]     [Yosemite]

  Powered by Linux