■遠田.jpブログ
› サイトマップ ›
MT活用
MT活用
遠田.jpブログはMT4で構築されている。
MTは3.3xから4.xに変わりMTIFというタグが使えるようになった。
そこで、MT4のMTIFを使ってパンくずリストを設置した。
使用したタグは以下のとおり。
(ヘッダモジュールの一番下に張り付けるだけ)
<!-- パンくずリストMT4開始 -->
<MTUnless name="main_index">
■<a href="<$MTBlogURL$>"><$MTBlogName encode_html="1"$></a>
<MTIf name="archive_index">
› <$MTGetVar name="page_title"$>
</MTIf>
<MTIf name="system_template">
› <$MTGetVar name="page_title"$>
</MTIf>
<MTIf name="datebased_archive">
› <a href="<$MTLink template="archive_index"$>">サイトマップ</a>
› <$MTGetVar name="page_title"$>
</MTIf>
<MTIfArchiveType archive_type="Author">
› <a href="<$MTLink template="archive_index"$>">サイトマップ</a>
› <$MTGetVar name="page_title"$>
</MTIfArchiveType>
<MTIfArchiveType archive_type="Category">
› <a href="<$MTLink template="archive_index"$>">サイトマップ</a> ›
<MTParentCategories glue=" > ">
<a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a>
</MTParentCategories>
</MTIfArchiveType>
<MTIfArchiveType archive_type="Individual">
› <a href="<$MTLink template="archive_index"$>">サイトマップ</a> ›
<MTParentCategories glue=" > ">
<a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a>
</MTParentCategories>
› <a href="<$MTEntryPermalink$>"><$MTGetVar name="page_title"$></a>
</MTIfArchiveType>
</MTUnless>
<!-- パンくずリストMT4ここまで -->
※このパンくずリストは SCREAMOさんの「パンくずリスト for Movable Type 4」を参考にして作成しました。
ありがとうございます>SCREAMOさん
MTは3.3xから4.xに変わりMTIFというタグが使えるようになった。
そこで、MT4のMTIFを使ってパンくずリストを設置した。
使用したタグは以下のとおり。
(ヘッダモジュールの一番下に張り付けるだけ)
<!-- パンくずリストMT4開始 -->
<MTUnless name="main_index">
■<a href="<$MTBlogURL$>"><$MTBlogName encode_html="1"$></a>
<MTIf name="archive_index">
› <$MTGetVar name="page_title"$>
</MTIf>
<MTIf name="system_template">
› <$MTGetVar name="page_title"$>
</MTIf>
<MTIf name="datebased_archive">
› <a href="<$MTLink template="archive_index"$>">サイトマップ</a>
› <$MTGetVar name="page_title"$>
</MTIf>
<MTIfArchiveType archive_type="Author">
› <a href="<$MTLink template="archive_index"$>">サイトマップ</a>
› <$MTGetVar name="page_title"$>
</MTIfArchiveType>
<MTIfArchiveType archive_type="Category">
› <a href="<$MTLink template="archive_index"$>">サイトマップ</a> ›
<MTParentCategories glue=" > ">
<a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a>
</MTParentCategories>
</MTIfArchiveType>
<MTIfArchiveType archive_type="Individual">
› <a href="<$MTLink template="archive_index"$>">サイトマップ</a> ›
<MTParentCategories glue=" > ">
<a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a>
</MTParentCategories>
› <a href="<$MTEntryPermalink$>"><$MTGetVar name="page_title"$></a>
</MTIfArchiveType>
</MTUnless>
<!-- パンくずリストMT4ここまで -->
※このパンくずリストは SCREAMOさんの「パンくずリスト for Movable Type 4」を参考にして作成しました。
ありがとうございます>SCREAMOさん
MT4ではアシアトログのタグを<MTIF>を使ってフッターに埋め込むことが可能になる。
アシアトログ
http://www.tohda.jp/cgi-bin/access/accview.cgi
で見ると、個別エントリー、カテゴリ、メインページ、検索ページの記録が取れている。
▼ここからフッターモジュールのタグに埋め込むアシアトログのタグ
<MTIf name="entry_template">
<script type="text/javascript">
<!--
document.write("<IMG src='http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTEntryPermalink$>&img=1&scr=", screen.width, "x", screen.height, "x", screen.colorDepth, "&ref=", escape(parent.document.referrer), "' border=0 width=1 height=1>");
//-->
</SCRIPT>
<noscript>
<IMG src="http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTEntryPermalink$>&img=1&ref=noScript" border=0 width=1 height=1>
</noscript>
</MTIf>
<MTIf name="Category_archive">
<script type="text/javascript">
<!--
document.write("<IMG src='http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTCategoryArchiveLink$>&img=1&scr=", screen.width, "x", screen.height, "x", screen.colorDepth, "&ref=", escape(parent.document.referrer), "' border=0 width=1 height=1>");
//-->
</SCRIPT>
<noscript>
<IMG src="http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTCategoryArchiveLink$>&img=1&ref=noScript" border=0 width=1 height=1>
</noscript>
</MTIf>
<MTIf name="search_results_template">
<script type="text/javascript">
<!--
document.write("<IMG src='http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=[search]<$MTBlogURL$>&img=1&scr=", screen.width, "x", screen.height, "x", screen.colorDepth, "&ref=", escape(parent.document.referrer), "' border=0 width=1 height=1>");
//-->
</SCRIPT>
<noscript>
<IMG src="http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=[search]<$MTBlogURL$>&img=1&ref=noScript" border=0 width=1 height=1>
</noscript>
</MTIf>
<MTIf name="main_index">
<script type="text/javascript">
<!--
document.write("<IMG src='http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTBlogURL$>&img=1&scr=", screen.width, "x", screen.height, "x", screen.colorDepth, "&ref=", escape(parent.document.referrer), "' border=0 width=1 height=1>");
//-->
</SCRIPT>
<noscript>
<IMG src="http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTBlogURL$>&img=1&ref=noScript" border=0 width=1 height=1>
</noscript>
</MTIf>
ここまで
※太字の部分はアシアトログのURLに変更すること
アシアトログ
http://www.tohda.jp/cgi-bin/access/accview.cgi
で見ると、個別エントリー、カテゴリ、メインページ、検索ページの記録が取れている。
▼ここからフッターモジュールのタグに埋め込むアシアトログのタグ
<MTIf name="entry_template">
<script type="text/javascript">
<!--
document.write("<IMG src='http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTEntryPermalink$>&img=1&scr=", screen.width, "x", screen.height, "x", screen.colorDepth, "&ref=", escape(parent.document.referrer), "' border=0 width=1 height=1>");
//-->
</SCRIPT>
<noscript>
<IMG src="http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTEntryPermalink$>&img=1&ref=noScript" border=0 width=1 height=1>
</noscript>
</MTIf>
<MTIf name="Category_archive">
<script type="text/javascript">
<!--
document.write("<IMG src='http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTCategoryArchiveLink$>&img=1&scr=", screen.width, "x", screen.height, "x", screen.colorDepth, "&ref=", escape(parent.document.referrer), "' border=0 width=1 height=1>");
//-->
</SCRIPT>
<noscript>
<IMG src="http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTCategoryArchiveLink$>&img=1&ref=noScript" border=0 width=1 height=1>
</noscript>
</MTIf>
<MTIf name="search_results_template">
<script type="text/javascript">
<!--
document.write("<IMG src='http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=[search]<$MTBlogURL$>&img=1&scr=", screen.width, "x", screen.height, "x", screen.colorDepth, "&ref=", escape(parent.document.referrer), "' border=0 width=1 height=1>");
//-->
</SCRIPT>
<noscript>
<IMG src="http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=[search]<$MTBlogURL$>&img=1&ref=noScript" border=0 width=1 height=1>
</noscript>
</MTIf>
<MTIf name="main_index">
<script type="text/javascript">
<!--
document.write("<IMG src='http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTBlogURL$>&img=1&scr=", screen.width, "x", screen.height, "x", screen.colorDepth, "&ref=", escape(parent.document.referrer), "' border=0 width=1 height=1>");
//-->
</SCRIPT>
<noscript>
<IMG src="http://www.tohda.jp/cgi-bin/access/accimg.cgi?id=<$MTBlogURL$>&img=1&ref=noScript" border=0 width=1 height=1>
</noscript>
</MTIf>
ここまで
※太字の部分はアシアトログのURLに変更すること



