-printf "<div class=\"msgreceived\"><p>View this report as an <a href=\"%s\">mbox folder</a>.</p></div>\n", bugurl($ref, "mbox");
-print "<HR>";
+
+if (looks_like_number($msg)) {
+ printf qq(<p><a href="%s">Full log</a></p>),html_escape(bug_url($ref));
+}
+else {
+ print qq(<p><a href="mailto:$ref\@$gEmailDomain">Reply</a> ),
+ qq(or <a href="mailto:$ref-subscribe\@$gEmailDomain">subscribe</a> ),
+ qq(to this bug.</p>\n);
+ print qq(<p><a href="javascript:toggle_infmessages();">Toggle useless messages</a></p>);
+ printf qq(<div class="msgreceived"><p>View this report as an <a href="%s">mbox folder</a>, ).
+ qq(<a href="%s">status mbox</a>, <a href="%s">maintainer mbox</a></p></div>\n),
+ html_escape(bug_url($ref, mbox=>'yes')),
+ html_escape(bug_url($ref, mbox=>'yes',mboxstatus=>'yes')),
+ html_escape(bug_url($ref, mbox=>'yes',mboxmaint=>'yes'));
+}