Changeset 2274 for trunk/template


Ignore:
Timestamp:
Mar 11, 2008, 3:04:27 AM (17 years ago)
Author:
rvelices
Message:
  • remove $confsubcatify (it was my reqquest to Pierrick when plugins were not available; now it can be done through plugin)
  • optimization when show_nb_comments true (1 sql query per page instead of 1 query per element)
  • some cleanup & more standard trigger names
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/template/yoga/thumbnails.tpl

    r2234 r2274  
    44<ul class="thumbnails">
    55{foreach from=$thumbnails item=thumbnail}
    6         <li class="{$thumbnail.CLASS}">
     6        <li>
    77        <span class="wrap1">
    88                <span class="wrap2">
    99                <a href="{$thumbnail.U_IMG_LINK}">
    10                         <img class="thumbnail" src="{$thumbnail.IMAGE}"
    11                 alt="{$thumbnail.IMAGE_ALT}"
    12                 title="{$thumbnail.IMAGE_TITLE}">
     10                        <img class="thumbnail" src="{$thumbnail.IMAGE}" alt="{$thumbnail.IMAGE_ALT}" title="{$thumbnail.IMAGE_TITLE}" />
    1311                </a>
    1412                </span>
     
    1614
    1715                {if !empty($thumbnail.ELEMENT_NAME)}{$thumbnail.ELEMENT_NAME}{/if}
    18                 {if !empty($thumbnail.CATEGORY_NAME)}{$thumbnail.CATEGORY_NAME}{/if}
    1916                {if !empty($thumbnail.IMAGE_TS)}{$thumbnail.IMAGE_TS}{/if}
    20                
    21                 {if !empty($thumbnail.nb_comments)}
    22                 <span class="{$thumbnail.nb_comments.CLASS} nb-comments">
     17
     18                {if isset($thumbnail.NB_COMMENTS)}
     19                <span class="{if 0==$thumbnail.NB_COMMENTS}zero {/if}nb-comments">
    2320                <br />
    24                 {$pwg->l10n_dec('%d comment', '%d comments',$thumbnail.nb_comments.NB_COMMENTS)}
     21                {$pwg->l10n_dec('%d comment', '%d comments',$thumbnail.NB_COMMENTS)}
    2522                </span>
    2623                {/if}
    27                
    28                 {if !empty($thumbnail.nb_hits)}
    29                 <span class="{$thumbnail.nb_hits.CLASS} nb-hits">
     24
     25                {if isset($thumbnail.NB_HITS)}
     26                <span class="{if 0==$thumbnail.NB_HITS}zero {/if}nb-hits">
    3027                <br />
    31                 {$pwg->l10n_dec('%d hit', '%d hits',$thumbnail.nb_hits.HITS)}
     28                {$pwg->l10n_dec('%d hit', '%d hits',$thumbnail.NB_HITS)}
    3229                </span>
    3330                {/if}
Note: See TracChangeset for help on using the changeset viewer.