Ignore:
Timestamp:
Dec 28, 2013, 6:08:42 PM (10 years ago)
Author:
mistic100
Message:

update for 2.6 + better calculation + option to force ratio
TODO: issue with PNG (unable to generate thumbnail with IM)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/header_manager/admin/template/config.tpl

    r20169 r26298  
    1 {combine_css path=$HEADER_MANAGER_PATH|@cat:"admin/template/style.css"}
     1{combine_css path=$HEADER_MANAGER_PATH|cat:'admin/template/style.css'}
    22
    3 {footer_script require="jquery"}{literal}
     3{footer_script require="jquery"}
    44jQuery("input[name='display']").change(function() {
    55  jQuery(".display-help:not(#"+ jQuery(this).val() +")").slideUp();
     
    1313  defaultPosition: 'top'
    1414});
    15 {/literal}{/footer_script}
     15{/footer_script}
    1616
    1717<div class="titrePage">
     
    2121<form method="post" action="{$CONFIG_URL}" class="properties">
    2222  <fieldset>
    23     <legend>{'Display'|@translate}</legend>
     23    <legend>{'Display'|translate}</legend>
    2424   
    25     <label><input type="radio" name="display" value="image_only" {if $BANNER_DISPLAY=='image_only'}checked="checked"{/if}> {'Image only'|@translate}</label><br>
     25    <label><input type="radio" name="display" value="image_only" {if $BANNER_DISPLAY=='image_only'}checked="checked"{/if}> {'Image only'|translate}</label><br>
    2626   
    27     <label><input type="radio" name="display" value="with_title" {if $BANNER_DISPLAY=='with_title'}checked="checked"{/if}> {'Gallery title above image'|@translate}</label><br>
     27    <label><input type="radio" name="display" value="with_title" {if $BANNER_DISPLAY=='with_title'}checked="checked"{/if}> {'Gallery title above image'|translate}</label><br>
    2828    <div class="display-help" id="with_title" {if $BANNER_DISPLAY!='with_title'}style="display:none;"{/if}>
    29       <i>{'You can customize the display by adding CSS rules to'|@translate}</i>
     29      <i>{'You can customize the display by adding CSS rules to'|translate}</i>
    3030      <span style="font-family:monospace;font-size:14px;color:#000;background:#eee;padding:0 2px;">#<span style="color:#09f;font-weight:bold;">theHeader</span> <span style="color:#00f;">div</span>.<span style="color:#f00;">banner</span></span>
    3131    </div>
    3232   
    33     <label><input type="radio" name="display" value="with_text" {if $BANNER_DISPLAY=='with_text'}checked="checked"{/if}> {'With text'|@translate}</label><br>
     33    <label><input type="radio" name="display" value="with_text" {if $BANNER_DISPLAY=='with_text'}checked="checked"{/if}> {'With text'|translate}</label><br>
    3434    <div class="display-help" id="with_text" {if $BANNER_DISPLAY!='with_text'}style="display:none;"{/if}>
    3535      <textarea rows="5" cols="50" class="description" name="conf_page_banner">{$CONF_PAGE_BANNER}</textarea><br>
    36       <i>{'Put <b>%header_manager%</b> where you want to display the image.'|@translate}</i>
     36      <i>{'Put <b>%header_manager%</b> where you want to display the image.'|translate}</i>
    3737    </div>
    3838   
    39     <label><input style="margin-top:20px;" type="checkbox" name="banner_on_picture" value="true" {if $BANNER_ON_PICTURE}checked="checked"{/if}> <b>{'Display banner on photo page'|@translate}</b></label>
     39    <label><input style="margin-top:20px;" type="checkbox" name="banner_on_picture" value="true" {if $BANNER_ON_PICTURE}checked="checked"{/if}> <b>{'Display banner on photo page'|translate}</b></label>
    4040  </fieldset>
    4141 
    4242  <fieldset id="batchManagerGlobal">
    43     <legend>{'Banner'|@translate}</legend>
     43    <legend>{'Banner'|translate}</legend>
    4444   
    4545  {if $banners}
    4646    <div class="banner-radio" style="display:block;">
    4747      <input type="radio" name="image" value="random" id="banner-random" {if $BANNER_IMAGE=='random'}checked="checked"{/if}>
    48       <label for="banner-random"><b>{'Random'|@translate}</b></label>
     48      <label for="banner-random"><b>{'Random'|translate}</b></label>
    4949    </div>
    5050    {foreach from=$banners item=image key=name}
     
    5454      </span>
    5555      <span class="banner-wrapper">
    56         <a href="{$CONFIG_URL}&amp;delete_banner={$image.NAME}" title="{'Delete'|@translate}" onclick="return confirm('{'Are you sure?'|@translate|@escape:javascript}');" class="delete-banner">&times;</a>
     56        <a href="{$CONFIG_URL}&amp;delete_banner={$image.NAME}" title="{'Delete'|translate}" onclick="return confirm('{'Are you sure?'|translate|@escape:javascript}');" class="delete-banner">&times;</a>
    5757        <span class="banner-size">{$image.SIZE[0]} &times; {$image.SIZE[1]} px</span>
    5858        <label for="banner-{$image.NAME}" title="{$name}"><img src="{$image.THUMB}" alt="{$image.NAME}"></label>
     
    6161    {/foreach}
    6262  {else}
    63     {'No banner added yet'|@translate}
     63    {'No banner added yet'|translate}
    6464  {/if}
    6565   
    6666    <br><br>
    67     <a href="{$ADD_IMAGE_URL}">{'Add a banner'|@translate}</a>
     67    <a href="{$ADD_IMAGE_URL}">{'Add a banner'|translate}</a>
    6868  </fieldset>
    6969
    70   <p class="formButtons"><input type="submit" name="save_config" value="{'Submit'|@translate}" class="submit"></p>
     70  <p class="formButtons"><input type="submit" name="save_config" value="{'Submit'|translate}" class="submit"></p>
    7171 
    7272  <fieldset>
    73     <legend>{'Album specific banners'|@translate}</legend>
    74     <i>{'In order to add a specific banner, go to the admin page of the desired album.'|@translate}</i>
     73    <legend>{'Album specific banners'|translate}</legend>
     74    <i>{'In order to add a specific banner, go to the admin page of the desired album.'|translate}</i>
    7575   
    7676  {if $categories}
     
    8080        {$cat.NAME}
    8181        <a class="showImage" title="<img src='{$banners[$cat.IMAGE].THUMB}'>"><img src="{$HEADER_MANAGER_PATH}admin/template/image_{$cat.DEEP}.png"></a>
    82         <a href="{$cat.U_DELETE}" title="{'Restore default banner'|@translate}" onclick="return confirm('{'Are you sure?'|@translate|@escape:javascript}');"><img src="{$themeconf.admin_icon_dir}/delete.png"></a>
     82        <a href="{$cat.U_DELETE}" title="{'Restore default banner'|translate}" onclick="return confirm('{'Are you sure?'|translate|@escape:javascript}');"><img src="{$themeconf.admin_icon_dir}/delete.png"></a>
    8383      </li>
    8484    {/foreach}
     
    8686   
    8787    <p>
    88       <img src="{$HEADER_MANAGER_PATH}admin/template/image_0.png"> : {'Non recursive'|@translate} &bull;
    89       <img src="{$HEADER_MANAGER_PATH}admin/template/image_1.png"> : {'Recursive'|@translate}
     88      <img src="{$HEADER_MANAGER_PATH}admin/template/image_0.png"> : {'Non recursive'|translate} &bull;
     89      <img src="{$HEADER_MANAGER_PATH}admin/template/image_1.png"> : {'Recursive'|translate}
    9090    </p>
    9191  {/if}
Note: See TracChangeset for help on using the changeset viewer.