<?php
$template = <<<END
<!-- lp1_faq -->
<section class="faq lp1_faq {val item/bg}" id="faq">
<!--{def item/title}-->
<h2>{val item/title}</h2>
<!--{/def}-->
<div class="text">
<dl>
<!--{each item/list}-->
<dt>{val item/list/question}</dt>
<dd class="markdown-body">{rval item/list/answer}</dd>
<!--{/each}-->
</dl>
<!--{def item/link}-->
<p class="btn3 white"><a href="{val item/link}">{val item/link_text}</a></p>
<!--{/def}-->
</div>
</section>
END;

$lp1_faq = array(
	"title" => "lp1よくある質問",
	"name" => "lp1_faq",			// 名称、重複すると正しく動作しません
	"template" => $template,		// ブロックのテンプレート
	"input" => array(
		"help" => array(
			"title" => "使い方",
			"type" => "comment",
			"link" => DOCUMENT1 . "/?act=lp1_faq",
			"class" => "notice",
		),
		"title" => array(
			"title" => "タイトル",
			"type" => "text",
		),
		"bg" => array(
			"title" => "背景",
			"type" => "select",
			"list" => array(
				"" => "なし",
				"bg1" => "あり",
			),
		),
		"dummy1" => array(
			"title" => " ",
			"type" => "comment",
		),
		"question1" => array(
			"title" => "質問1",
			"type" => "text",
		),
		"answer1" => array(
			"title" => "回答1",
			"type" => "textarea",
		),
		"dummy2" => array(
			"title" => " ",
			"type" => "comment",
		),
		"question2" => array(
			"title" => "質問2",
			"type" => "text",
		),
		"answer2" => array(
			"title" => "回答2",
			"type" => "textarea",
		),
		"dummy3" => array(
			"title" => " ",
			"type" => "comment",
		),
		"question3" => array(
			"title" => "質問3",
			"type" => "text",
		),
		"answer3" => array(
			"title" => "回答3",
			"type" => "textarea",
		),
		"dummy4" => array(
			"title" => " ",
			"type" => "comment",
		),
		"question4" => array(
			"title" => "質問4",
			"type" => "text",
		),
		"answer4" => array(
			"title" => "回答4",
			"type" => "textarea",
		),
		"dummy5" => array(
			"title" => " ",
			"type" => "comment",
		),
		"question5" => array(
			"title" => "質問5",
			"type" => "text",
		),
		"answer5" => array(
			"title" => "回答5",
			"type" => "textarea",
		),
		"dummy6" => array(
			"title" => " ",
			"type" => "comment",
		),
		"link" => array(
			"title" => "リンク",
			"type" => "text",
		),
		"link_text" => array(
			"title" => "リンクタイトル",
			"type" => "text",
		),
	),
	"repeat" => array(
		"question", "answer",
	),
);

block_add($lp1_faq);
