]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - index.php
rewording, php-4.0.6 fixes, Log removed from index.php
[SourceForge/phpwiki.git] / index.php
1 <?php // -*-php-*-
2 // iso-8859-1
3
4 /*
5 Copyright 1999,2000,2001,2002,2003,2004 $ThePhpWikiProgrammingTeam 
6 = array(
7 "Steve Wainstead", "Clifford A. Adams", "Lawrence Akka", 
8 "Scott R. Anderson", "Jon Åslund", "Neil Brown", "Jeff Dairiki",
9 "Stéphane Gourichon", "Jan Hidders", "Arno Hollosi", "John Jorgensen",
10 "Antti Kaihola", "Jeremie Kass", "Carsten Klapp", "Marco Milanesi",
11 "Grant Morgan", "Jan Nieuwenhuizen", "Aredridel Niothke", 
12 "Pablo Roca Rozas", "Sandino Araico Sánchez", "Joel Uckelman", 
13 "Reini Urban", "Joby Walker", "Tim Voght", "Jochen Kalmbach");
14
15 This file is part of PhpWiki.
16
17 PhpWiki is free software; you can redistribute it and/or modify
18 it under the terms of the GNU General Public License as published by
19 the Free Software Foundation; either version 2 of the License, or
20 (at your option) any later version.
21
22 PhpWiki is distributed in the hope that it will be useful,
23 but WITHOUT ANY WARRANTY; without even the implied warranty of
24 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
25 GNU General Public License for more details.
26
27 You should have received a copy of the GNU General Public License
28 along with PhpWiki; if not, write to the Free Software
29 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
30 */
31
32 require_once (dirname(__FILE__).'/lib/prepend.php');
33 rcs_id('$Id: index.php,v 1.143 2004-05-01 16:04:56 rurban Exp $');
34
35 require_once(dirname(__FILE__).'/lib/IniConfig.php');
36 IniConfig(dirname(__FILE__)."/config/config.ini");
37
38 ////////////////////////////////////////////////////////////////
39 // PrettyWiki
40 // Check if we were included by some other wiki version 
41 // (getimg.php, en, de, wiki, ...) or not. 
42 // If the server requested this index.php fire up the code by loading lib/main.php.
43 // Parallel wiki scripts can now simply include /index.php for the 
44 // main configuration, extend or redefine some settings and 
45 // load lib/main.php by themselves. See the file 'wiki'.
46 // This overcomes the IndexAsConfigProblem.
47 // Generally a simple 
48 //   define('VIRTUAL_PATH', $_SERVER['SCRIPT_NAME']);
49 // is enough in the wiki file, plus the action definition in a .htaccess file
50 ////////////////////////////////////////////////////////////////
51
52 // If your lib/main.php is not loaded, comment that out, and  
53 // uncomment the include "lib/main.php" line below.
54 if (defined('VIRTUAL_PATH') and defined('USE_PATH_INFO')) {
55     if ($HTTP_SERVER_VARS['SCRIPT_NAME'] != VIRTUAL_PATH) {
56         include(dirname(__FILE__)."/lib/main.php");
57     }
58     elseif (defined('SCRIPT_NAME') and 
59             ($HTTP_SERVER_VARS['SCRIPT_NAME'] != SCRIPT_NAME)) {
60         include(dirname(__FILE__)."/lib/main.php");
61     }
62 } else {
63     if (defined('SCRIPT_NAME') and 
64         ($HTTP_SERVER_VARS['SCRIPT_NAME'] == SCRIPT_NAME)) {
65         include(dirname(__FILE__)."/lib/main.php");
66     } elseif (strstr($HTTP_SERVER_VARS['PHP_SELF'],'index.php')) {
67         include(dirname(__FILE__)."/lib/main.php");
68     }
69 }
70 //include (dirname(__FILE__)."/lib/main.php");
71
72 // (c-file-style: "gnu")
73 // Local Variables:
74 // mode: php
75 // tab-width: 8
76 // c-basic-offset: 4
77 // c-hanging-comment-ender-p: nil
78 // indent-tabs-mode: nil
79 // End:   
80 ?>