source: trunk/themes/default/template/comment_list.tpl @ 23384

Last change on this file since 23384 was 23384, checked in by rvelices, 11 years ago

smarty 3 - first pass for tests

  • Property svn:eol-style set to LF
File size: 3.6 KB
RevLine 
[12930]1{if isset($comment_derivative_params)}
2{strip}{html_style}
[13801]3.commentElement .illustration{ldelim}
4        width: {$comment_derivative_params->max_width()+5}px
[12930]5}
6
[13697]7.content .commentElement .description{ldelim}
[18995]8        min-height: {$comment_derivative_params->max_height()+5}px
[12930]9}
10{/html_style}{/strip}
11{/if}
[20212]12{footer_script}var error_icon = "{$ROOT_URL}{$themeconf.icon_dir}/errors_small.png";{/footer_script}
[20452]13<div class="loader"><img src="{$ROOT_URL}{$themeconf.img_dir}/ajax_loader.gif"></div>
[13697]14<ul class="commentsList">
[2983]15{foreach from=$comments item=comment name=comment_loop}
[13801]16<li class="commentElement {if $smarty.foreach.comment_loop.index is odd}odd{else}even{/if}">
[12930]17        {if isset($comment.src_image)}
[16522]18        {if isset($comment_derivative_params)}
19        {assign var=derivative value=$pwg->derivative($comment_derivative_params, $comment.src_image)}
20        {else}
21        {assign var=derivative value=$pwg->derivative($derivative_params, $comment.src_image)}
22        {/if}
23        {if !$derivative->is_cached()}
24        {combine_script id='jquery.ajaxmanager' path='themes/default/js/plugins/jquery.ajaxmanager.js' load='footer'}
[20211]25  {combine_script id='thumbnails.loader' path='themes/default/js/thumbnails.loader.js' require='jquery.ajaxmanager' load='footer'}
26  {/if}
[7877]27        <div class="illustration">
28                <a href="{$comment.U_PICTURE}">
[20211]29                <img {if $derivative->is_cached()}src="{$derivative->get_url()}"{else}src="{$ROOT_URL}{$themeconf.icon_dir}/img_small.png" data-src="{$derivative->get_url()}"{/if} alt="{$comment.ALT}">
[7877]30                </a>
31        </div>
32        {/if}
[18995]33        <div class="description">
[12676]34                {if isset($comment.U_DELETE) or isset($comment.U_VALIDATE) or isset($comment.U_EDIT)}
35                <div class="actions" style="float:right;font-size:90%">
[7877]36                {if isset($comment.U_DELETE)}
[12676]37                        <a href="{$comment.U_DELETE}" onclick="return confirm('{'Are you sure?'|@translate|@escape:javascript}');">
38                                {'Delete'|@translate}
[15924]39                        </a>{if isset($comment.U_VALIDATE) or isset($comment.U_EDIT) or isset($comment.U_CANCEL)} | {/if}
40                {/if}
41                {if isset($comment.U_CANCEL)}
42                        <a href="{$comment.U_CANCEL}">
43                                {'Cancel'|@translate}
[18995]44                        </a>{if isset($comment.U_VALIDATE)} | {/if}
[7877]45                {/if}
46                {if isset($comment.U_EDIT) and !isset($comment.IN_EDIT)}
[12676]47                        <a class="editComment" href="{$comment.U_EDIT}#edit_comment">
48                                {'Edit'|@translate}
49                        </a>{if isset($comment.U_VALIDATE)} | {/if}
[7877]50                {/if}
51                {if isset($comment.U_VALIDATE)}
[12676]52                        <a href="{$comment.U_VALIDATE}">
53                                {'Validate'|@translate}
[7877]54                        </a>
[12676]55                {/if}&nbsp;
[8362]56                </div>
[7877]57                {/if}
58
[18748]59                <span class="commentAuthor">{if $comment.WEBSITE_URL}<a href="{$comment.WEBSITE_URL}" class="external" target="_blank" rel="nofollow">{$comment.AUTHOR}</a>{else}{$comment.AUTHOR}{/if}</span>
[23384]60                        {if isset($comment.EMAIL)}- <a href="mailto:{$comment.EMAIL}">{$comment.EMAIL}</a>{/if}
[18748]61                        - <span class="commentDate">{$comment.DATE}</span>
[7877]62                {if isset($comment.IN_EDIT)}
63                <a name="edit_comment"></a>
[13865]64                <form method="post" action="{$comment.U_EDIT}" id="editComment">
[18995]65                        <p><label for="contenteditid">{'Edit a comment'|@translate} :</label></p>
[13865]66                        <p><textarea name="content" id="contenteditid" rows="5" cols="80">{$comment.CONTENT|@escape}</textarea></p>
[18995]67                        <p><label for="website_url">{'Website'|@translate} :</label></p>
68                        <p><input type="text" name="website_url" id="website_url" value="{$comment.WEBSITE_URL}" size="40"></p>
[13865]69                        <p><input type="hidden" name="key" value="{$comment.KEY}">
70                                <input type="hidden" name="pwg_token" value="{$comment.PWG_TOKEN}">
[7877]71                                <input type="hidden" name="image_id" value="{$comment.IMAGE_ID|@default:$current.id}">
[12479]72                                <input type="submit" value="{'Submit'|@translate}">
[13865]73                        </p>
[7877]74                </form>
75                {else}
76                <blockquote><div>{$comment.CONTENT}</div></blockquote>
77                {/if}
78        </div>
[3446]79</li>
[2480]80{/foreach}
[3185]81</ul>
Note: See TracBrowser for help on using the repository browser.