Location: PHPKode > projects > Blandware AtLeap Lite - CMS on PHP > atleaplite/smarty/templates/browser/files.tpl
{* Smarty template *}
{assign var="buttonsNumber" value="1"}
{assign var="columnsNumber" value=4}
{math assign="totalCells" equation="x+y" x=$columnsNumber y=$buttonsNumber}
<table border="0" cellpadding="0" cellspacing="0" class="grid" id="resourceList">
    <tr class="filter">
    <form action="{buildUrl}" method="GET">
        {initFilters}
        <td>
            {textFilter colon='fileName'}
        </td>
        <td>
            {textFilter colon='title'}
        </td>
        <td></td>
        <td>
            {*{filterValue colon='resource_active' assign='resource_activeFilter' escape=false}
            <select name="{filterName colon='resource_active'}" class="form_filter_short">
                {html_options options=$allYesNoList selected=$resource_activeFilter}
            </select>*}
        </td>
        <td align="center" colspan="{$buttonsNumber}"><input type="submit" value="{message key='common.button.filter'}" class="form_filter_button noTopBottomMargin"></td>
    </form>
    </tr>
    
    <tr> 
        <th><a href="{sortLink colon='fileName'}">{message key='resource.form.fileName'}</a></th>
        <th><a href="{sortLink colon='title'}">{message key='resource.form.title'}</a></th>
        <th><a href="{sortLink colon='size'}">{message key='resource.form.size'}</a></th>
        <th>{*<a href="{sortLink colon='resource_active'}">*}{message key='resource.form.active'}{*</a>*}</th>
        <th colspan="{$buttonsNumber}"></th>
    </tr>
    {if !$dataIsEmpty}
    {foreach name="mainLoop" from=$data item=resource}
    {cycle name="resources" values="oddRow,evenRow" assign=parity}
    <tr class="{$parity}" onMouseOver="onMouseOverRow(this)" onMouseOut="onMouseOutRow(this)">
        <td>{$resource->file_name|escape}</td>
        <td>{$resource->title|escape}</td>
        <td>{$resource->size|escape}</td>
        <td>{$resource->isActiveYesno()|escape}</td>
        <td class="gridIcon">
            <a href="javascript:sendUrl('{buildUrl fileName=$resource->file_name friendly='resource'}')" title="{message key='common.select'}">
                <img src="images/select.gif" border="0" alt="{message key='common.select'}">
            </a>
        </td>
    </tr>
    {/foreach}
    {else}
        <tr>
            <td class="tfoot" colspan="{$totalCells}" align="center">
                <em>{message key='resource.message.nothing'}</em>
            </td>
        </tr>
    {/if}
    </form>
</table>


{include file="after_grid.tpl"}
Return current item: Blandware AtLeap Lite - CMS on PHP