source: extensions/rv_menutree/branches/2.1-pat/rvtree_menubar_categories.tpl @ 6390

Last change on this file since 6390 was 6390, checked in by patdenice, 14 years ago

Create branch 2.1

File size: 2.2 KB
Line 
1{known_script id="rvtree" src=$RVMT.PATH|@cat:"rvtree.js" }
2{html_head}
3<style type="text/css">
4{$RVMT.CSS}
5</style>
6{/html_head}
7
8<dt>
9  {if isset($U_START_FILTER)}
10  <a href="{$U_START_FILTER}" title="{'display only recently posted images'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/start_filter.png" class="button" alt="start filter"></a>
11  {/if}
12  {if isset($U_STOP_FILTER)}
13  <a href="{$U_STOP_FILTER}" title="{'return to the display of all images'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/stop_filter.png" class="button" alt="stop filter"></a>
14  {/if}
15        <a href="{$block->data.U_CATEGORIES}">{'Categories'|@translate}</a>
16</dt>
17<dd>
18{assign var='ref_level' value=0}
19{foreach from=$block->data.MENU_CATEGORIES item=cat key=key}
20  {if $cat.LEVEL > $ref_level}
21          {if $ref_level == 0}
22                  <ul class="rvTree" id="theCategoryMenu">
23                {else}
24                  <ul>
25                {/if}
26  {else}
27    </li>
28    {'</ul></li>'|@str_repeat:$ref_level-$cat.LEVEL}
29  {/if}
30    <li class="
31                                        {if $cat.SELECTED}selected{/if}
32                                        {if $cat.count_categories > 0}
33                                                {if $RVMT_ALL_OPEN}liOpen
34                                                {elseif isset($RVMT.UPPER_IDS[$cat.id])}liOpen
35                                                  {assign var=RVMT.UPPER_IDS[$cat.id] value=null}
36                                                {else}liClosed{/if}
37                                        {/if}
38                ">
39      <a href="{$cat.URL}" {if $cat.IS_UPPERCAT}rel="up"{/if} title="{$cat.TITLE}">{$cat.NAME}</a>
40      {if $cat.count_images > 0}
41      <span class="{if $cat.nb_images > 0}menuInfoCat{else}menuInfoCatByChild{/if}" title="{$cat.TITLE}">[{$cat.count_images}]</span>
42      {/if}
43      {if !empty($cat.icon_ts)}
44      <img title="{$cat.icon_ts.TITLE}" src="{$ROOT_URL}{$themeconf.icon_dir}/recent{if $cat.icon_ts.IS_CHILD_DATE}_by_child{/if}.png" class="icon" alt="(!)">
45      {/if}
46  {assign var='ref_level' value=$cat.LEVEL}
47{/foreach}
48{'</li></ul>'|@str_repeat:$ref_level}
49
50        {if isset($block->data.U_UPLOAD)}
51        <ul>
52                <li>
53                        <a href="{$block->data.U_UPLOAD}">{'Upload a picture'|@translate}</a>
54                </li>
55        </ul>
56        {/if}
57        <p class="totalImages">{$pwg->l10n_dec('%d image', '%d images', $block->data.NB_PICTURE)}</p>
58</dd>
59{$RVMT.UPPER_IDS|@var_dump}
60<script type="text/javascript">
61  RVTree.convertTree( document.getElementById("theCategoryMenu") );
62</script>
Note: See TracBrowser for help on using the repository browser.