Comments on Visible Comments
Source : Alex Schroeder: Diary
I’m currently experimenting with this variant:*MyOldPrintFooter = *PrintFooter; *PrintFooter = *MyNewPrintFooter;
sub MyNewPrintFooter { my $id = $_[0]; if ($id and $CommentsPrefix and $id !~ /^$CommentsPrefix(.*)/o) { my $target = $CommentsPrefix . $id; if ($IndexHash{$target}) { print $q->p({-class=>'comment'}, GetPageLink($target, T('Read Comments'), 'comment')); } else { print $q->p({-class=>'comment'}, GetPageLink($target, T('Add Comment'), 'comment')); } } MyOldPrintFooter(@_); } Thus, the link to the comment page will not repeat the page title, and there is a different text depending on whether a comment page exists or not.As comment pages can be reworked, it’s hard to actually count the comments by looking at the text. It would be possible to store a counter on the comment page that was different from the revision number [..]
le 19.09.08 à 11:10
dans Mind
-
Article précédent - Commenter - Article suivant -