{template header}
<div class="subtable nav" style="width: {TABLEWIDTH}">
<a href="$indexname">$bbname</a> &raquo;
<!--{if !$action}-->{lang faq}<!--{else}--><a href="faq.php">{lang faq}</a> $navigation<!--{/if}-->
</div><br>

<div class="simpletable" style="width: {TABLEWIDTH}; text-align: left">
<div class="header">{lang faq_search}</div><div class="altbg2 smalltxt" align="center">
<form method="post" action="faq.php?action=search&searchsubmit=yes">
<input type="hidden" name="formhash" value="{FORMHASH}">
<input type="text" name="keyword" size="30" value="$keyword">
<select name="searchtype">
	<option value="all">{lang faq_search_title_and_content}</option>
	<option value="title">{lang faq_search_title}</option>
	<option value="message">{lang faq_search_content}</option>
</select>
<input class="button" type="submit" name="searchsubmit" value="{lang submit}">
</form>
</div></div><br>

<!--{if !$action}-->
	<!--{loop $faqparent $parent}-->
		<div class="simpletable" style="width: {TABLEWIDTH}; text-align: left">
		<div class="header">$parent[title]</div><div class="altbg2 smalltxt">
		<ul style="margin: 2px auto;">
		<!--{loop $faqsub[$parent[id]] $sub}-->
			<li><a href="faq.php?action=message&amp;id=$sub[id]">$sub[title]</a></li>
		<!--{/loop}-->
		</ul>
		</div></div><br>
	<!--{/loop}-->
<!--{elseif $action == 'message'}-->
	<!--{if $otherlist}-->
		<div class="simpletable" style="width: {TABLEWIDTH}; text-align: left">
		<div class="header">{lang faq_related}</div><div class="altbg2 smalltxt">
		<ul style="margin: 2px auto;">
			<!--{loop $otherlist $other}-->
				<li><a href="faq.php?action=message&amp;id=$other[id]">$other[title]</a></li>
			<!--{/loop}-->
		</ul>
		</div></div><br>
	<!--{/if}-->
	<div class="simpletable" style="width: {TABLEWIDTH}; text-align: left">
	<div class="header">$faq[title]</div>
	<div class="altbg2" style="margin: 8px auto;">$faq[message]</div>
	</div><br>
<!--{elseif $action == 'search'}-->
	<!--{loop $faqlist $faq}-->
		<div class="simpletable" style="width: {TABLEWIDTH}; text-align: left">
		<div class="header">$faq[title]</div>
		<div class="altbg2" style="margin: 8px auto;">$faq[message]</div>
		</div><br>
	<!--{/loop}-->
<!--{/if}-->
{template footer}