3,12 → 3,10 |
require '../_taios.php'; |
|
$page = new Taios_Page('Add Category', '../'); |
$page->drawHeader(); |
$page->drawMiddle(); |
|
$page->checkLoggedIn(); |
|
$parentID = $_GET['parentID']; |
$parentID = $_POST['parentID']; |
if (empty($parentID)) |
{ |
$parentID = -1; |
24,7 → 22,7 |
$page->redirect('add-category.php?error=No Title Specified'); |
} |
|
$page->query('INSERT INTO ForumCategories (0, ' . $parentID . ', "' . $title . '", "' . $description . '")'); |
$page->query('INSERT INTO ForumCategories VALUES (0, ' . $parentID . ', "' . $title . '", "' . $description . '")'); |
$page->redirect('index.php?parentID=' . $parentID); |
} |
else |
32,7 → 30,5 |
$page->drawError('You do not have permission to access this page.'); |
} |
|
$page->drawFooter(); |
|
?> |
|