{literal}
<script type="text/javascript">         
jQuery(function() {  
jQuery("#q").suggest("?do=forums&sub=searchattachments",{/*onSelect: function() {alert(this.value)}*/}); 
});
</script>
<style type="text/css">
.ac_results {width:201px}
</style>
{/literal}

<form name="attsearch" id="attsearch" method="post" action="">
  <table width="100%"  border="0" cellpadding="4" cellspacing="1" class="tableborder">
    <tr>
      <td class="header">{#Forums_Att_SAtt#}</td>
    </tr>
    <tr>
      <td class="firstrow">
      <input class="input" name="q" type="text" id="q" size="30" style="width:200px" value="{$smarty.request.q|escape:'html'}" />
     
		<select class="input" n name="pp" id="pp">

{section name=pp loop=95 step=5}

<option value="{$smarty.section.pp.index+10}" {if $smarty.request.pp == $smarty.section.pp.index+10}selected{/if}>{$smarty.section.pp.index+10} {#Global_EachPage#}</option>
{/section}
 </select>
        <input type="submit" class="button" value="{#Forums_Att_SAtt#}" />
      </td>
    </tr>
  </table>
</form>
<form action="" method="post" enctype="multipart/form-data" name="kform" id="kform">
  <table width="100%"  border="0" cellpadding="4" cellspacing="0">
    <tr>
      <td colspan="4" class="header">{#Forums_Att_Att#}</td>
    </tr>
    <tr>
      <td class="headers"><a href="?do=forums&sub=showattachments&amp;sort=name&amp;ext={$smarty.request.ext}&amp;pp={$smarty.request.pp}">{#Global_Name#}</a></td>
      <td align="center" class="headers"><a href="?do=forums&sub=showattachments&amp;sort=hits&amp;ext={$smarty.request.ext}&amp;pp={$smarty.request.pp}">{#Global_Hits#}</a></td>
      <td class="headers">&nbsp;</td>
      <td class="headers"> 
        <label><input name="allbox" type="checkbox" id="d" onclick="selall();" value="" />{#Global_SelAll#}</label>
      </td>
    </tr>
    {foreach from=$attachments item="sm"}
    <tr style="font-weight:normal" class="{cycle name='att' values='second,first'}">
      <td width="20%" nowrap="nowrap"><a  href="?do=forums&amp;sub=showattachments&amp;dl=1&amp;id={$sm->id}"><strong>{$sm->orig_name}</strong></a> </td>
      <td align="center" nowrap="nowrap"> {$sm->hits} </td>
      <td align="center">{$sm->sizes}</td>
      <td>
        <label><input name="del[{$sm->filename}]" type="checkbox" id="d" value="1" /> {#Global_Delete#}</label></td>
    </tr>
    {/foreach}
  </table>
  <input type="submit" class="button big" value="{#Forums_Att_bDel#}" />
  <input name="save" type="hidden" id="save" value="1">
</form>
{if $navi}
<div class="navi_div">
{$navi}
</div>
{/if}