投稿ページに 新しい投稿、ホーム、前の投稿 を追加
デモ
https://s-o-h-o.blogspot.com/2024/12/Cat.html
最初の方だけ以下を参考
Post pagination in Blogger's newer themes (including custom next/previous post titles)
https://10wontips.blogspot.com/2018/04/post-pagination-in-bloggers-newer.html
<b:includable id='postFooter' var='post'> を探して
その下に
<b:include cond='data:view.isPost' name='postPagination'/> をコピー
(テンプレート構造をチェックしていないので、ここが正しいに場所になるのかどうかは未確認です)
これは Contempo だと上から3番目になるんですが、Contempo はやり方がちょっと異なるので
CSS
.blog-pager .blog-pager-newer-link,.blog-pager .home-link{ display:none }
よくわかりませんが、元から消えてるのに非表示になってるので、CSSを削除
必要に応じて home-link を非表示にしてください
その下にでも以下のCSSを追加
.blog-pager-newer-link{float:left}.blog-pager-older-link{float:right}.blog-pager{margin:1em 0;text-align:center;overflow:hidden}
ホーム のリンクにタイトル属性を追加
<b:includable id='homePageLink'> で検索
<b:includable id='homePageLink'>
<a class='home-link' expr:href='data:blog.homepageUrl' expr:title='data:messages.home'>
<data:messages.home/>
</a>
</b:includable>
postPagination
<b:includable id='postPagination'>
<div class='blog-pager container' id='blog-pager'>
<b:include cond='data:newerPageUrl' name='previousPageLink'/>
<b:include cond='data:olderPageUrl' name='nextPageLink'/>
<b:include cond='data:view.url != data:blog.homepageUrl' name='homePageLink'/>
</div>
<div class='clear'/>
</b:includable>
CSS
div.clear{clear:both}





0 comments:
スパム対策の為コメントをオフにしています。
Disqusは利用出来ます。
注: コメントを投稿できるのは、このブログのメンバーだけです。