Ticket #708 (closed defect (bug): fixed)

Opened 7 years ago

Last modified 7 years ago

IXR lib cannot call server methods contained in a class object

Reported by: ringmaster Owned by: matt
Priority: normal Milestone:
Component: XML-RPC Version: 1.5
Severity: minor Keywords:
Cc: ringmaster

Description

Using the new 'xmlrpc_methods' plugin hook, I tried to create a new XML-RPC method via a plugin. My plugin code is contained in a class to avoid namespace issues (See:  http://codex.wordpress.org/Plugin_API#Avoiding_Function_Name_Collisions ).

I added the method to the method list using the class object array method ( $callback=array(&$myobject, 'methodname') ), but IXR_Server cannot execute methods declared in this manner. As a result, the only way to implement XML-RPC server methods inside a class is to extend the IXR_Server class, which can't be done from the xmlrpc_methods hook in WordPress.

Attachments

class-IXR.php.patch Download (1.1 KB) - added by ringmaster 7 years ago.

Change History

  • Patch set to No
  • Patch changed from No to Yes

comment:3   matt7 years ago

Looks groovy

comment:4   matt7 years ago

  • Owner changed from anonymous to matt
  • fixed_in_version set to 1.5
  • Status changed from new to closed
  • Resolution changed from 10 to 20
Note: See TracTickets for help on using tickets.