note 40206 added to ref.xmlrpc

From: Date: Wed, 25 Feb 2004 09:34:15 +0000
Subject: note 40206 added to ref.xmlrpc
Groups: php.notes 
Request: Send a blank email to php-notes+get-65699@lists.php.net to get a copy of this message
Just a quick addition to my previous xmlrpc_client class: since you cannot use remote methods containing capital letters or methods from subhandlers (like 'system.listMethods()'), I added a 'call(...)' method to the class. <?php // this method should be copy/pasted in the // xmlrpc_client class function call($function) { $return = NULL; $argv = func_get_args(); array_shift($argv); // remove function argument $this->__call($function, $argv, &$return); return $return; } // now, you can also do $result = $client->call('system.listMethods'); $sum = client->call('add', '1', '2'); ?> ---- Manual Page -- http://www.php.net/manual/en/ref.xmlrpc.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+40206 Delete -- http://master.php.net/manage/user-notes.php?action=delete+40206&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+40206&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#65699) next »