问题
I have a non-WSDL SOAP working on two servers of mine. There is a lag issue cause of usage I guess. I am trying to use called class instead of calling SOAP each time using my functions.
server-side.php
class soapGlobal {
public function __construct() {
}
public static function hashFunction() {
//some function...
}
public static function siteFunction() {
//some function...
}
public static function encryptFunction() {
//some function...
}
public static function decryptFunction() {
//some function...
}
public static function remoteIPFunction() {
//some function...
}
//some more function...
public function __destruct() {
}
}
$server = new SoapServer(null, array("uri" => "https://globalurl"));
$server->setClass("soapGlobal");
$server->handle();
Can I call SOAP functions with
soapGlobal::FUNCTION
rather than
$client->FUNCTION
来源:https://stackoverflow.com/questions/57320043/how-to-call-server-side-class-of-soap-in-client-side-code