Delicious Bookmark this on Delicious Share on Facebook SlashdotSlashdot It! Digg! Digg



PHP : Function Reference : SOAP Functions : SoapServer->setPersistence()

SoapServer->setPersistence()

Sets persistence mode of SoapServer ()

Example 2287. Some examples

<?php

$server
->setPersistence(SOAP_PERSISTENCE_SESSION);

$server->setPersistence(SOAP_PERSISTENCE_REQUEST);

?>

Code Examples / Notes » soap_soapserver_setpersistence

jared

I had some issues getting session persistence (SOAP_PERSISTENCE_SESSION) to work. I finally got it working after setting session.auto_start=0, and then only calling session_start() in the script containing the SoapServer. Maybe this is obvious, but took me a bit to figure it out.
I only tried it with session.use_cookies=1, so if the settings above don't work for you, make sure cookies are enabled, though it may work without the need for cookies.


cperez1000

Always remember to place the "setPersistence" method before the handle method, otherwise it won't work.  It sounds obvious, but it's still a very common mistake, since no errors are shown.

Change Language


Follow Navioo On Twitter
is_soap_fault
SoapClient->__call()
SoapClient->__construct()
SoapClient->__doRequest()
SoapClient->__getFunctions()
SoapClient->__getLastRequest()
SoapClient->__getLastRequestHeaders()
SoapClient->__getLastResponse()
SoapClient->__getLastResponseHeaders()
SoapClient->__getTypes()
SoapClient->__setCookie()
SoapClient->__soapCall()
SoapFault->__construct()
SoapHeader->__construct()
SoapParam->__construct()
SoapServer->addFunction()
SoapServer->__construct()
SoapServer->fault()
SoapServer->getFunctions()
SoapServer->handle()
SoapServer->setClass()
SoapServer->setPersistence()
SoapVar->__construct()
use_soap_error_handler
eXTReMe Tracker