source: extensions/Slimi/template/thumbnails.tpl @ 25998

Last change on this file since 25998 was 25998, checked in by Miklfe, 10 years ago
File size: 2.5 KB
Line 
1{define_derivative name='carousel' width='300' height='300' min_width='300'}
2{php}
3    global $page, $template;
4    $template->assign('cat_name', $page['category']['name']);
5{/php}
6
7
8<div id="carousel">
9<div id="wrap">
10                <div class="jcarousel">
11<ul>
12                {if !empty($category_thumbnails)}
13               
14                {foreach from=$category_thumbnails item=cat}
15
16
17                        <li>
18                                        <div class="illustration">
19                                                <a href="{$cat.URL}">
20                                                        <img src="{$pwg->derivative_url($carousel, $cat.representative.src_image)}" alt="{$cat.TN_ALT}" title="{$cat.NAME|@replace:'"':' '|@strip_tags:false} - {'display this album'|@translate}" min-width="{$carousel->max_width()}" height="{$carousel->max_height()}"/>
21                                                </a>
22                                        </div>
23                                       
24                                               
25                                                <div class="CatMPdescription">
26                                                        <h3>
27                                                                <a href="{$cat.URL}">{$cat.NAME}</a>
28                                                        </h3>
29                                                        <div>
30                                                        {$cat.CAPTION_NB_IMAGES}
31                                                        </div> 
32                                                </div>
33                        </li>
34                {/foreach}{/if}
35
36
37        {foreach from=$thumbnails item=thumbnail}
38        {assign var=derivative value=$pwg->derivative($carousel, $thumbnail.src_image)}
39                        <li>
40                                <div class="illustration">
41                                        <a href="{if ($Slimi.lytebox_slimi)==1}{$thumbnail.path}" class="lytebox" rev="slide:true group:name showNavigation:true navType:1 slideInterval:6000"{else}{$thumbnail.URL}"{/if} title="{$thumbnail.NAME|strip_tags:false|replace:'\'':'&#39;'|replace:'"':'&quot;'}">
42                                        <img class="thumbnail" src="{$derivative->get_url()}" alt="{$thumbnail.TN_ALT}" title="{$thumbnail.TN_TITLE}" height="{$carousel->max_height()}"/>
43                                               
44                                                {if $SHOW_THUMBNAIL_CAPTION }
45                                                        <div class="CatMPdescription">
46                                                                <H3>
47                                                                        {$thumbnail.NAME}
48                                                                       
49                                                                        {if !empty($thumbnail.icon_ts)}
50                                                                                <img title="{$thumbnail.icon_ts.TITLE}" src="{$ROOT_URL}{$themeconf.icon_dir}/recent.png" alt="(!)">
51                                                                        {/if}
52                                                                </h3>
53                                                                {if isset($thumbnail.NB_COMMENTS) or isset($thumbnail.NB_HITS)}
54                                                                <div>
55                                                                        {if isset($thumbnail.NB_COMMENTS)}
56                                                                                <p class="{if 0==$thumbnail.NB_COMMENTS}zero {/if}nb-comments">
57                                                                                {$pwg->l10n_dec('%d comment', '%d comments',$thumbnail.NB_COMMENTS)}
58                                                                                </p>
59                                                                        {/if}
60                                                                        {if isset($thumbnail.NB_HITS)}
61                                                                                <p class="{if 0==$thumbnail.NB_HITS}zero {/if}nb-hits">
62                                                                                {$pwg->l10n_dec('%d hit', '%d hits',$thumbnail.NB_HITS)}
63                                                                                </p>
64                                                                        {/if}
65                                                                </div>
66                                                                {/if}
67                                                        </div>
68                                                {/if}
69                                        </a>   
70                                </div> 
71                        </li>
72        {/foreach}
73</ul>
74
75</div>
76</div>
77        <a href="#" class="jcarousel-control-prev">&lsaquo;</a>
78    <a href="#" class="jcarousel-control-next">&rsaquo;</a>
79</div>
Note: See TracBrowser for help on using the repository browser.