Subversion Repositories taios

Compare Revisions

Ignore whitespace Rev 289 → Rev 275

/projects/edit-project.php
6,8 → 6,6
$page->drawHeader();
$page->drawMiddle();
 
$page->checkLoggedIn();
 
$project = $page->getProject($page->getGetID());
if (!$project)
{
/forums/add-post-do.php
File deleted
/forums/add-post.php
File deleted
/forums/delete-category-do.php
File deleted
/forums/edit-category-do.php
File deleted
/forums/edit-category.php
File deleted
/forums/index.php
17,20 → 17,12
{
write('<a href="index.php?parentID=-1">Back to root</a>');
}
if ($page->isLoggedIn())
if ($page->isUserAdmin($page->getLoggedInUser()))
{
if ($parentID != -1)
{
write(' &middot; ');
}
write('<a href="add-post.php?categoryID=' . $parentID . '">Add Post</a>');
}
if ($page->isUserAdmin($page->getLoggedInUser()))
{
if ($page->isLoggedIn())
{
write(' &middot; ');
}
write('<a href="add-category.php?parentID=' . $parentID . '">Add Category</a>');
}
write('</p><br />');
49,7 → 41,7
write('<p>' . $forumCategory->description . '</p>');
if ($page->isUserAdmin($page->getLoggedInUser()))
{
write('<p class="bold"><a href="edit-category.php?id=' . $forumCategory->ID . '">Edit Category</a> &nbsp;&nbsp; &middot; &nbsp;&nbsp; <a href="delete-category-do.php?id=' . $forumCategory->ID . '">Delete Category</a></p>');
write('<p class="bold"><a href="edit-category.php?id=' . $forumCategory->ID . '">Edit Category</a> &nbsp;&nbsp; &middot; &nbsp;&nbsp; <a href="delete-category.php?id=' . $forumCategory->ID . '">Delete Category</a></p>');
}
write('<br />');
}
/forums/post.php
9,21 → 9,16
$id = $page->getGetID();
$forumPost = $page->getForumPost($id);
write('<p class="bold"><a href="index.php?parentID=' . $forumPost->category->ID . '">Back to Topics</a></p><br />');
 
write('<h3>' . $forumPost->title . '</h3>');
write('<h5 style="color: #666666;">Posted On ' . date('l j F Y', $forumPost->datePosted) . ' by ' . $forumPost->author->name . ' (' . $forumPost->author->username . ')</h5>');
write('<p>' . $page->replaceBBCode($forumPost->content) . '</p>');
if ($page->isLoggedIn())
{
write('<p class="bold"><a href="add-post.php?parentID=' . $id . '">Post Reply</a></p>');
}
write('<br />');
 
$ids = $page->findIDs('ForumPosts', 'WHERE ParentID = ' . $id . ' ORDER BY DatePosted ASC');
$ids = $page->findIDs('ForumPosts', 'WHERE ParentID = ' . $id . ' ORDER BY DatePosted DESC');
for ($i = 0; $i < count($ids); $i++)
{
$forumPost = $page->getForumPost($ids[$i]);
write('<h4>' . $forumPost->title . '</h4>');
write('<h5 style="color: #666666;">Posted On ' . date('l j F Y', $forumPost->datePosted) . ' by ' . $forumPost->author->name . ' (' . $forumPost->author->username . ')</h5>');
write('<p>' . $page->replaceBBCode($forumPost->content) . '</p>');
write('<br />');
}