]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - index.php3
This commit was generated by cvs2svn to compensate for changes in r2,
[SourceForge/phpwiki.git] / index.php3
1 <?
2    /*
3       The main page, i.e. the main loop.
4       This file is always called first.
5    */
6
7    include "wiki_config.php3";
8    include "wiki_stdlib.php3";
9    include "wiki_dbmlib.php3";
10
11    // All requests require the database
12    if ($copy) {
13       // we are editing a copy and want the archive
14       $dbi = OpenDataBase($ArchiveDataBase);
15       include "wiki_editpage.php3";
16       CloseDataBase($dbi);
17       exit();
18    } else {
19       // live database
20       $dbi = OpenDataBase($WikiDataBase);
21    }
22
23
24    if ($edit) {
25       include "wiki_editpage.php3";
26    } elseif ($links) {
27       include "wiki_editlinks.php3";
28    } elseif ($search) {
29       include "wiki_search.php3";
30    } elseif ($full) {
31       include "wiki_fullsearch.php3";
32    } elseif ($post) {
33       include "wiki_savepage.php3";
34    } else {
35       include "wiki_display.php3"; // defaults to FrontPage
36    }
37
38    CloseDataBase($dbi);
39
40 ?>