[wp-trac] [WordPress Trac] #14933: IXR_Server->call() fails when calling method that uses __call()
WordPress Trac
wp-trac at lists.automattic.com
Wed Sep 22 18:39:31 UTC 2010
#14933: IXR_Server->call() fails when calling method that uses __call()
--------------------------------------------+-------------------------------
Reporter: dave1010 | Owner:
Type: defect (bug) | Status: reopened
Priority: normal | Milestone: Awaiting Review
Component: XML-RPC | Version: 3.0.1
Severity: normal | Resolution:
Keywords: IXR extending xmlrpc has-patch |
--------------------------------------------+-------------------------------
Comment(by dave1010):
I am using the xml_rpc filter (inside a class):
{{{
// lots of code snipped
class MyXmlRpc {
public function __construct() {
add_filter( 'xmlrpc_methods', array($this, 'add_new_xmlrpc_methods')
);
}
public function add_new_xmlrpc_methods($methods) {
foreach ($this->methods as $method) {
$methods[$this->PREFIX . $method] = array($this, $method);
}
return $methods;
}
public function __call($method, $args) {
// ... does lots of things with $method and $args here
return call_user_func_array(array($this, $method), $args);
}
}
}}}
I think I even used your how to :-)
--
Ticket URL: <http://core.trac.wordpress.org/ticket/14933#comment:6>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list