Last active
August 1, 2016 04:25
-
-
Save semicolon/78dcaecac8cba8e6d0c0 to your computer and use it in GitHub Desktop.
Movable Type のエントリー情報を JSON ファイルに出力するテンプレート。キーを単純数値にするため、ToI企画さんの「データをJSON形式で出力する裏ワザ (http://tec.toi-planning.net/mt-column/tips/post-6/) 」を改変しています。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<mt:SetVar name="entries" function="undef" /> | |
<mt:SetVar name="idx" value="0" /> | |
<mt:Entries> | |
<mt:SetVar name="e" function="undef" /> | |
<mt:SetHashVar name="e"> | |
<mt:EntryID setvar="entry_id" /> | |
<mt:EntryTitle setvar="entry_title" /> | |
<mt:EntryBody setvar="entry_body" /> | |
</mt:SetHashVar> | |
<mt:SetVar name="entries" key="$idx" value="$e" /> | |
<mt:SetVar name="idx" op="+" value="1" /> | |
</mt:Entries> | |
<mt:Var name="entries" to_json="1"/> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment