summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoey Hess <joey@gnu.kitenet.net>2008-12-17 20:29:55 -0500
committerJoey Hess <joey@gnu.kitenet.net>2008-12-17 20:29:55 -0500
commit81165dd2e079fac822eaefacafaaa612524b3aa6 (patch)
treee6b7b84a9ef53107b5c810bfafc846b34d64149f
parent339bfbd44a438f7bb712d76f6e7ee9c1f4784254 (diff)
jump to comments anchor after post
Not ideal, it would be nicer to jump to the actual comment posted, but no anchor is available.
-rw-r--r--IkiWiki/Plugin/comments.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/IkiWiki/Plugin/comments.pm b/IkiWiki/Plugin/comments.pm
index db829f344..2ca2d0a1d 100644
--- a/IkiWiki/Plugin/comments.pm
+++ b/IkiWiki/Plugin/comments.pm
@@ -500,7 +500,8 @@ sub sessioncgi ($$) {
error($conflict) if defined $conflict;
# Bounce back to where we were, but defeat broken caches
- my $anticache = "?updated=$page/$config{comments_pagename}$i";
+ # and jump to the comments anchor.
+ my $anticache = "?updated=$page/$config{comments_pagename}$i#comments";
IkiWiki::redirect($cgi, urlto($page, undef, 1).$anticache);
}
else {