3 * Copyright © 2002 Lawrence Akka
4 * Copyright © 2002 Jeff Dairiki
5 * Copyright © 2005,2007 Reini Urban
7 * This file is part of PhpWiki.
9 * PhpWiki is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * PhpWiki is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License along
20 * with PhpWiki; if not, write to the Free Software Foundation, Inc.,
21 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
23 * SPDX-License-Identifier: GPL-2.0-or-later
28 * The guts of this code have been moved to lib/XmlRpcServer.php.
30 * This file is really a vestige, as now, you can direct XML-RPC
31 * request to the main wiki URL (e.g. index.php) --- it will
32 * notice that you've POSTed content-type of text/xml and
33 * fire up the XML-RPC server automatically.
36 // Intercept GET requests from confused users. Only POST is allowed here!
37 if (empty($GLOBALS['HTTP_SERVER_VARS']))
38 $GLOBALS['HTTP_SERVER_VARS'] =& $_SERVER;
39 if ($_SERVER['REQUEST_METHOD'] != "POST") {
40 die('This is the address of the XML-RPC interface.' .
41 ' You must use XML-RPC calls to access information here.');
44 // Constant defined to indicate to phpwiki that it is being accessed via XML-RPC
45 define ("WIKI_XMLRPC", true);
47 // Start up the main code
48 include_once 'index.php';
49 include_once 'lib/main.php';
51 include_once 'lib/XmlRpcServer.php';
53 $server = new XmlRpcServer();