<?php
#
# Copyright 2003 James Seng. See LICENSE for the Software License.
#

$conf_basedir = '';

include_once "${conf_basedir}includes/xmlrpcs.inc";
include_once "${conf_basedir}includes/pong.inc";

$functions = array("pong.version" => array("function" => "pong_version"));

function pong_version($params) {
    global $conf_version;
    return new xmlrpcresp(new xmlrpcval($conf_version,"string"));
}

if (isset($module_tree) && isset($module_tree->submod)) {
    foreach ($module_tree->submod as $name => $v) {
        if (method_exists($module_tree->submod[$name],"xmlrpc")) {
            $functions = array_merge($functions,
                $module_tree->submod[$name]->module_invoke("","xmlrpc"));
        }
    }
}

$server = new xmlrpc_server($functions);

?>
