source: extensions/simple_themes/simple/template/thumbnails.tpl @ 16030

Last change on this file since 16030 was 16030, checked in by plg, 8 years ago

compatibility with Piwigo 2.4

File size: 1.7 KB
Line 
1{if !empty($thumbnails)}{strip}
2{combine_script id='jquery.ajaxmanager' path='themes/default/js/plugins/jquery.ajaxmanager.js' load='footer'}
3{combine_script id='thumbnails.loader' path='themes/default/js/thumbnails.loader.js' require='jquery.ajaxmanager' load='footer'}
4{*define_derivative name='derivative_params' width=160 height=90 crop=true*}
5{html_style}
6{*Set some sizes according to maximum thumbnail width and height*}
7.thumbnails SPAN,
8.thumbnails .wrap2 A,
9.thumbnails LABEL{ldelim}
10        width: {$derivative_params->max_width()+2}px;
11}
12
13.thumbnails .wrap2{ldelim}
14        height: {$derivative_params->max_height()+3}px;
15}
16{if $derivative_params->max_width() > 600}
17.thumbLegend {ldelim}font-size: 130%}
18{else}
19{if $derivative_params->max_width() > 400}
20.thumbLegend {ldelim}font-size: 110%}
21{else}
22.thumbLegend {ldelim}font-size: 90%}
23{/if}
24{/if}
25{/html_style}
26<ul>
27  {foreach from=$thumbnails item=thumbnail}
28    {assign var=derivative value=$pwg->derivative($derivative_params, $thumbnail.src_image)}
29  <li>
30    <a href="{$thumbnail.URL}">
31      <img class="thumbnail" {if !$derivative->is_cached()}data-{/if}src="{$derivative->get_url()}" alt="{$thumbnail.TN_ALT}" title="{$thumbnail.TN_TITLE}">
32    </a>
33    {if $SHOW_THUMBNAIL_CAPTION }
34    <p>
35      {if isset($thumbnail.NAME)}{$thumbnail.NAME}{/if}
36          {if !empty($thumbnail.icon_ts)}
37          <img title="{$thumbnail.icon_ts.TITLE}" src="{$ROOT_URL}{$themeconf.icon_dir}/recent.png" class="icon" alt="(!)">
38          {/if}
39      {if isset($thumbnail.NB_COMMENTS)}
40      <span class="{if 0==$thumbnail.NB_COMMENTS}zero {/if}nb-comments">
41        ({$pwg->l10n_dec('%d comment', '%d comments',$thumbnail.NB_COMMENTS)})
42      </span>
43      {/if}
44    </p>
45    {/if}
46  </li>
47{/foreach}{/strip}
48</ul>
49{/if}
Note: See TracBrowser for help on using the repository browser.