55379c90df
修改了上一个版本的一些错误,第一次提交
38 lines
1.1 KiB
PHP
38 lines
1.1 KiB
PHP
<?php
|
|
/*
|
|
IXR - The Inutio XML-RPC Library - (c) Incutio Ltd 2002
|
|
Version 1.61 - Simon Willison, 11th July 2003 (htmlentities -> htmlspecialchars)
|
|
Site: http://scripts.incutio.com/xmlrpc/
|
|
Manual: http://scripts.incutio.com/xmlrpc/manual.php
|
|
Made available under the Artistic License: http://www.opensource.org/licenses/artistic-license.php
|
|
*/
|
|
|
|
/** IXR_Clinet */
|
|
require_once 'IXR/Clinet.php';
|
|
|
|
/**
|
|
* IXR客户端
|
|
*
|
|
* @package IXR
|
|
*/
|
|
class IXR_ClientMulticall extends IXR_Client {
|
|
var $calls = array();
|
|
function IXR_ClientMulticall($server, $path = false, $port = 80) {
|
|
parent::IXR_Client($server, $path, $port);
|
|
$this->useragent = 'The Incutio XML-RPC PHP Library (multicall client)';
|
|
}
|
|
function addCall() {
|
|
$args = func_get_args();
|
|
$methodName = array_shift($args);
|
|
$struct = array(
|
|
'methodName' => $methodName,
|
|
'params' => $args
|
|
);
|
|
$this->calls[] = $struct;
|
|
}
|
|
function query() {
|
|
// Prepare multicall, then call the parent::query() method
|
|
return parent::query('system.multicall', $this->calls);
|
|
}
|
|
}
|