Ignore:
Timestamp:
Aug 21, 2008, 3:14:03 AM (16 years ago)
Author:
rvelices
Message:
  • tried to reduce the number of css rules and selectors (most gains on menubar and usercomments) tested with IE6,IE7,FF,Opera9,Safari3
File:
1 edited

Legend:

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

    r2479 r2480  
    179179  </td></tr>
    180180  {/if}
     181
    181182  {if isset($rate_summary) }
    182183  <tr>
     
    192193  </tr>
    193194  {/if}
     195 
     196{if isset($rating)}
     197        <tr>
     198                <td class="label">
     199                        <span id="updateRate">{if isset($rating.USER_RATE)}{'update_rate'|@translate}{else}{'new_rate'|@translate}{/if}</span>
     200                </td>
     201                <td class="value">
     202                        <form action="{$rating.F_ACTION}" method="post" id="rateForm" style="margin:0;">
     203                        <div>&nbsp;
     204                        {foreach from=$rating.marks item=mark name=rate_loop}
     205                        {if !$smarty.foreach.rate_loop.first} | {/if}
     206                        {if isset($rating.USER_RATE) && $mark==$rating.USER_RATE}
     207                          <input type="button" name="rate" value="{$mark}" class="rateButtonSelected" />
     208                        {else}
     209                          <input type="submit" name="rate" value="{$mark}" class="rateButton" />
     210                        {/if}
     211                        {/foreach}
     212                        <script type="text/javascript" src="{$ROOT_URL}{$themeconf.template_dir}/rating.js"></script>
     213                        <script type="text/javascript">
     214                        makeNiceRatingForm( {ldelim}rootUrl: '{$ROOT_URL|@escape:"javascript"}', image_id: {$current.id},
     215                        updateRateText: "{'update_rate'|@translate|@escape:'javascript'}", updateRateElement: document.getElementById("updateRate"),
     216                        ratingSummaryText: "{'%.2f (rated %d times, standard deviation = %.2f)'|@translate|@escape:'javascript'}", ratingSummaryElement: document.getElementById("ratingSummary") {rdelim} );
     217                        </script>
     218                        </div>
     219                        </form>
     220                </td>
     221        </tr>
     222{/if}
     223
    194224</table>
    195225
     
    210240{/if}
    211241
    212 {if isset($rating)}
    213 <form action="{$rating.F_ACTION}" method="post" id="rateForm">
    214 <div>
    215 <span id="updateRate">{if isset($rating.USER_RATE)}{'update_rate'|@translate}{else}{'new_rate'|@translate}{/if}</span>
    216 :
    217 {foreach from=$rating.marks item=mark name=rate_loop}
    218 {if !$smarty.foreach.rate_loop.first} | {/if}
    219 {if isset($rating.USER_RATE) && $mark==$rating.USER_RATE}
    220   <input type="button" name="rate" value="{$mark}" class="rateButtonSelected" />
    221 {else}
    222   <input type="submit" name="rate" value="{$mark}" class="rateButton" />
    223 {/if}
    224 {/foreach}
    225 <script type="text/javascript" src="{$ROOT_URL}{$themeconf.template_dir}/rating.js"></script>
    226 <script type="text/javascript">
    227 makeNiceRatingForm( {ldelim}rootUrl: '{$ROOT_URL|@escape:"javascript"}', image_id: {$current.id},
    228 updateRateText: "{'update_rate'|@translate|@escape:'javascript'}", updateRateElement: document.getElementById("updateRate"),
    229 ratingSummaryText: "{'%.2f (rated %d times, standard deviation = %.2f)'|@translate|@escape:'javascript'}", ratingSummaryElement: document.getElementById("ratingSummary") {rdelim} );
    230 </script>
    231 </div>
    232 </form>
    233 {/if}
    234242
    235243<hr class="separation">
     
    242250
    243251  {if isset($comments)}
    244   {foreach from=$comments item=comment}
    245   <div class="comment">
    246     {if isset($comment.U_DELETE)}
    247     <p class="userCommentDelete">
    248     <a href="{$comment.U_DELETE}" title="{'comments_del'|@translate}">
    249       <img src="{$ROOT_URL}{$themeconf.icon_dir}/delete.png" class="button" style="border:none;vertical-align:middle; margin-left:5px;" alt="[{'delete'|@translate}]"/>
    250     </a>
    251     </p>
    252     {/if}
    253     <p class="commentInfo"><span class="author">{$comment.AUTHOR}</span> - {$comment.DATE}</p>
    254     <blockquote>{$comment.CONTENT}</blockquote>
    255   </div>
    256   {/foreach}
     252                {include file='comment_list.tpl'}
    257253  {/if}
    258254
     
    274270{/if} {*comments*}
    275271
     272
     273
    276274{if !empty($PLUGIN_PICTURE_AFTER)}{$PLUGIN_PICTURE_AFTER}{/if}
Note: See TracChangeset for help on using the changeset viewer.