Subversion Repositories taios

Rev

Rev 305 | Rev 363 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
169 tom 1
<?php
2
 
3
require '../_taios.php';
4
 
224 tom 5
$pageName = $_GET['page'];
225 tom 6
if (empty($pageName))
221 tom 7
{
224 tom 8
    $pageName = 'Index';
221 tom 9
}
169 tom 10
 
227 tom 11
$page = new Taios_Page('Wiki - ' . $pageName, '../');
12
$page->drawHeader();
361 tom 13
write('<h3>Wiki</h3>');
14
$page->drawMenuItem('Special', 'specialpage.php');
227 tom 15
$page->drawMiddle();
16
 
305 tom 17
write('<p><i>The wiki is still under construction.</i></p>');
18
 
228 tom 19
if ($page->isUserGM($page->getLoggedInUser()))
20
{
21
    write('<p><a href="edit.php?page=' . $pageName . '">Edit Page</a></p><br />');
22
}
23
 
225 tom 24
$filename = 'pages/' . $pageName . '.txt';
25
 
230 tom 26
$fp = @fopen($filename, 'r');
221 tom 27
if ($fp)
28
{
226 tom 29
    write('<p>' . $page->replaceBBCode(fread($fp, filesize($filename))) . '</p>');
221 tom 30
    fclose($fp);
31
}
32
else
33
{
34
    write('<p>This page is empty.</p>');
35
}
36
 
169 tom 37
$page->drawFooter();
38
 
39
?>
40