Subversion Repositories taios

Rev

Rev 283 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

<?php

require '../_taios.php';

$page = new Taios_Page('Add Post', '../');
$page->drawHeader();
$page->drawMiddle();

$page->checkLoggedIn();

$parentID = $_GET['parentID'];
if (empty($parentID))
{
    $parentID = -1;
}

$categoryID = $_GET['categoryID'];
if (empty($categoryID))
{
    $categoryID = -1;
}

if ($page->isLoggedIn())
{

if (isset($_GET['error']))
{
    $page->drawError($_GET['error'], false);
}

?>

<form action="add-post-do.php" method="POST">
<input type="hidden" name="parentID" value="<?php echo $parentID; ?>" />
<input type="hidden" name="categoryID" value="<?php echo $categoryID; ?>" />
<table>
<tr>
<td class="bold">Title: </td>
<td><input type="text" name="title" /></td>
</tr>
<tr>
<td class="bold">Content: </td>
<td><textarea name="content"></textarea></td>
</tr>
<tr>
<td></td>
<td><input type="submit" value="Add" /></td>
</tr>
</table>
</form>

<?php
}
else
{
    $page->drawError('You do not have permission to access this page.');
}

$page->drawFooter();

?>