選択されているタグ : ablogcms , カスタマイズ

タグを絞り込む : CSS CSS3 highslide jQuery php prettyPhoto テーマ モジュール 負荷軽減

Entry_Continue を使うようにカスタマイズする

通常は続きを読むのリンク部分をクリックすると1つの記事が表示されるようになりますが、Entry_Continue というモジュールを利用するとページの遷移無しに続き部分を読み込んでくる事ができるようになります。

続きを読む部分を表示するテンプレートを準備します。

include/continue.html

<!-- BEGIN_MODULE Entry_Continue -->

<!-- BEGIN column:veil -->
<!--#include file="/include/column.html"-->
<hr class="clearHidden" />
<!-- END column:veil -->
				
<!-- END_MODULE Entry_Continue -->

そして、一覧のテンプレートファイルにある continueLink 部分を探してみて下さい。

<!-- BEGIN continueLink:veil -->
<p class="continueLink clear"><a href="{continueUrl}">「{continueName}」の続きを読む</a></p>
<!-- END continueLink:veil -->

の部分を、以下のように修正します。

<!-- BEGIN continueLink:veil -->
<form action="{continueUrl}" method="post" class="js-post_include">
<input type="hidden" name="tpl" value="include/continue.html" />
<input type="submit" name="ACMS_POST_2GET" value=" {continueName}の続きを読む " />
</form>
<!-- END continueLink:veil -->

今回のページの遷移無しにコンテンツを読み込む機能を a-blog cms では Post include 機能と呼びます。関連する公式のマニュアルコンテンツを紹介しておきます。

似たような事をするとページャー部分を同様に読み込んでくる事ができるようになるハズです。次のエントリーでページャー部分をカスタマイズするエントリーを書いてみようと思います。


blog comments powered by Disqus

プロフィール

山本一道
  • Twitter
  • Facebook
  • Google+

有限会社アップルップル

山本 一道

名古屋のホームページ制作会社「有限会社アップルップル」の代表をしています。弊社で開発しているCMS「a-blog cms」や、名古屋の「WCAN」も、よろしくお願いします。

エントリーリスト

カテゴリーリスト

タグ