{extends "base_full.tpl.html"}
{block title}Internal FAQ{if $faq|default:'' != ''} - {$faq.faq_title}{/if}{/block}

{block "content"}

{if $faq|default:'' != ''}
{if $faq|default:'' == -1}
<span><p><b>{t}Error: You are not allowed to view the requested FAQ entry.{/t}</b></p></span>
{else}
<table class="bordered">
    <tr class="title">
        <th>{$faq.faq_title|escape:"html"}</th>
    </tr>
    <tr>
        <td>
            <p><i>{t}Last Updated{/t}: {$faq.faq_updated_date|timeago}</i></p>
            {$faq.message}
        </td>
    </tr>
</table>
        <a href="faq.php">Back to Internal FAQ</a>
<br />
{/if}
{else}
<table class="bordered grid">
    <tr class="title">
        <th colspan="2">
            {t}Article Entries{/t}
        </th>
    </tr>
    <tr>
        <th>{t}Title{/t}</th>
        <th>{t}Last Updated Date{/t}</th>
    </tr>
    {section name="i" loop=$faqs}
    <tr class="{cycle values='odd,even'}">
        <td><b><a href="faq.php?id={$faqs[i].faq_id}" title="{t}read faq entry{/t}">{$faqs[i].faq_title|escape:"html"}</a></b></td>
        <td>{$faqs[i].faq_updated_date|timeago}</td>
    </tr>
    {/section}
    </tr>
</table>
{/if}

{/block}
