Do you want your Perl code on one server to call your PHP functions on another? "Impossible!" you say? Not with XML-RPC. XML-RPC is a standard way for any application to make requests and recieve responses from methods written in any language. Interested? I knew you would be.
This extension is by far the best way of implementing XML-RPC in PHP. Being an extension to PHP and not a class or set of methods as the other solutions are, it is written in C and is therefore much faster than any of the other solutions.
The XML-RPC extension is not compiled with PHP by default. In order to enable it, you will need to download the PHP 4.1.0 or greater source from http://www.php.net/downloads.php and run the configure script including the switch:
and compile and install as usual.
Doing this will make
available several new XML-RPC functions for use in your PHP scripts.
Now, the built in XML-RPC functions are certainly not a joy to use, unless all you want to do is encode PHP variables into XML-RPC requests. The built-in functions will not make the actual requests themselves. I'll show you how to deal with this later in the article.