summaryrefslogtreecommitdiff
path: root/forum/utils
diff options
context:
space:
mode:
authordeva <deva>2010-07-06 13:22:50 +0000
committerdeva <deva>2010-07-06 13:22:50 +0000
commitd163efa5921431c8c9ebcf312052e549c18c9e12 (patch)
treeb74cfa27e71745ad4c8d75c65c46db651a7d6242 /forum/utils
parent093e36530916e21c09cbe55efd03d2825fe820b4 (diff)
More informative navigation system.
Diffstat (limited to 'forum/utils')
-rw-r--r--forum/utils/posts.php13
1 files changed, 11 insertions, 2 deletions
diff --git a/forum/utils/posts.php b/forum/utils/posts.php
index 59678de..f29354e 100644
--- a/forum/utils/posts.php
+++ b/forum/utils/posts.php
@@ -184,7 +184,16 @@ class Posts {
public function show()
{
global $current_user;
- echo " <h1 id=\"top\">" . $this->thread->name . "</h1>\n";
+
+ echo " <p><a href=\"#menu_bottom\">Down to the bottom</a>";
+ foreach($this->posts_linear as $post) {
+ if($post->date > $this->thread->lastseen[$current_user->uid]) {
+ echo " <a href=\"#firstunread\">Down to first unread</a>\n";
+ break;
+ }
+ }
+ echo "</p>\n";
+ echo " <h1>" . $this->thread->name . "</h1>\n";
/* // Recursive
foreach($this->posts as $post) {
@@ -211,7 +220,7 @@ class Posts {
$this->write();
- echo " <p><a href=\"#top\">Back to the top</a></p>\n";
+ echo " <p><a href=\"#menu_top\">Up to the top</a></p>\n";
}
private function recurser($parentpost, $element)