<!--<?php
include_once PrintEot('left');print <<<EOT
-->
<div class="admin_info mb10">
	<h3 class="h1">hook使用機制</h3>
    <div class="legend">
    在代碼中用︰pwHook::runHook('hookname'); 添加hook<br/>
    在/hook/目錄創建和第一步上的hookname相同的目錄<br/>
    在後台安裝該hook
    </div>
</div>
<form action="$basename&action=setmode" method="post" name="submit">
  <h2 class="h1">擴展模式設置</h2>
  <div class="admin_table mb10">
    <table width="100%" cellspacing="0" cellpadding="0">
      <tr class="tr1 vt">
            <td class="td1">是否開發模式</td>
            <td class="td2">
           	 	<div class="list_A list_80">
                    <ul class="cc">
                        <li><input type="radio" value="1" name="hookmode" $hookmode[1] />是</li>
                        <li><input type="radio" value="0" name="hookmode" $hookmode[0] />否</li>
                    </ul>
                </div>
            </td>
        </tr>
    </table>
  </div>
<div class="mb10 tac">
<span class="btn"><span><button type="submit" name="submit">提 交</button></span></span>
</div>
</form>

<h2 class="h1">已啟用擴展</h2>
<div class="admin_table mb10">
<table cellpadding="0" cellspacing="0" width="100%">
       <tr class="tr2 vt td_bgB">
         <td>擴展key</td>
         <td>操作</td>
       </tr>
<!--
EOT;
foreach ($usedHooks as $value) {
print <<<EOT
-->
		<tr class="tr1 vt">
         <td class="td2">{$value}</td>
         <td class="td2">
         <a href="$basename&action=updatecache&hook={$value}" class="mr20">更新</a> 
<!--
EOT;
if (!in_array($value,pwHook::getSystemHooks())) {
print <<<EOT
-->         
         <a href="$basename&action=uninstall&hook={$value}" class="mr20">關閉</a>
<!--
EOT;
}
print <<<EOT
-->
         </td>
       </tr>
<!--
EOT;
}
print <<<EOT
-->
</table>
</div>

<h2 class="h1">未啟用擴展</h2>
<div class="admin_table mb10">
<table cellpadding="0" cellspacing="0" width="100%">
       <tr class="tr2 vt td_bgB">
         <td>擴展key</td>
         <td>操作</td>
       </tr>
<!--
EOT;
foreach ($unUsedHooks as $value) {
print <<<EOT
-->
		<tr class="tr1 vt">
         <td class="td2">{$value}</td>
         <td class="td2"><a href="$basename&action=install&hook={$value}" class="mr20">開啟</a></td>
       </tr>
<!--
EOT;
}
print <<<EOT
-->
</table>
</div>
<!--
EOT;
include_once PrintEot('adminbottom');
?>-->