How to sort the comments on Confluence page in reverse order
プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。
サーバー*製品のサポートは 2024 年 2 月 15 日に終了しました。サーバー製品を利用している場合は、アトラシアンのサーバー製品のサポート終了のお知らせページにて移行オプションをご確認ください。
*Fisheye および Crucible は除く
要約
How to reverse the order of comments on a Confluence page
ソリューション
As this is a Customisation, please test it in your stage environment before implementing it into Production.
- Go to Confluence Admin | Look & Feel | Custom HTML| Edit
- Add the below lines under "At the end of the head" section
<script>
function reverseCommentOrder() {
$comments = AJS.$('#page-comments');
$comments.children().each(function(i,li){$comments.prepend(li)});
}
AJS.toInit(function ($) {
// reverse the comment order
reverseCommentOrder();
// add a link to reverse the order
$('#comments-section-title').append('<a id="page-comments-reverse" href="#">(Reverse Order)</a>');
$('#page-comments-reverse')
.css({ 'color':'#999','font-size':'0.65em'})
.click(function (e) {
reverseCommentOrder();
e.preventDefault();
});
});
</script>
- Click on Save
Before Adding the customization
After Adding the Customization
最終更新日 2023 年 7 月 21 日
Powered by Confluence and Scroll Viewport.