source: extensions/BatchDownloader/template/download_button.tpl @ 23359

Last change on this file since 23359 was 23359, checked in by mistic100, 11 years ago

typo in language files, fix for ghtumb, fix for question_mark_in_urk=false

File size: 1.7 KB
Line 
1{footer_script require='jquery'}
2var batchdown_count = {$BATCH_DWN_COUNT};
3var batchdown_string = "{'Confirm the download of %d pictures?'|@translate}";
4{literal}
5jQuery().ready(function() {
6  jQuery("#batchDownloadLink").click(function() {
7          var elt = jQuery("#batchDownloadBox");
8
9    elt.css("left", Math.min( jQuery(this).offset().left, jQuery(window).width() - elt.outerWidth(true) - 5))
10      .css("top", jQuery(this).offset().top + jQuery(this).outerHeight(true))
11      .toggle();
12
13    return false;
14  });
15
16  jQuery("#batchDownloadBox").on("mouseleave click", function() {
17    jQuery(this).hide();
18  });
19 
20  jQuery("#batchDownloadBox a").click(function() {
21    return confirm(batchdown_string.replace('%d', batchdown_count));
22  });
23});
24{/literal}{/footer_script}
25
26{html_style}{literal}
27.downloadSizeDetails {font-style:italic; font-size:80%;}
28{/literal}{/html_style}
29
30<li><a href="{$BATCH_DWN_URL}" id="batchDownloadLink" title="{'Download all pictures of this selection'|@translate}" class="pwg-state-default pwg-button" rel="nofollow">
31  <span class="pwg-icon batch-downloader-icon" style="background:url('{$ROOT_URL}{$BATCH_DOWNLOAD_PATH}template/images/zip.png') center center no-repeat;">&nbsp;</span><span class="pwg-button-text">{'Download'|@translate}</span>
32</a></li>
33
34<div id="batchDownloadBox" class="switchBox" style="display:none">
35  <div class="switchBoxTitle">{'Download'|@translate} - {'Photo sizes'|@translate}</div>
36  {foreach from=$BATCH_DOWNLOAD_SIZES item=size name=loop}{if !$smarty.foreach.loop.first}<br>{/if}
37  <a href="{$BATCH_DWN_URL}{$size.TYPE}" rel="nofollow">
38    {$size.DISPLAY} {if $size.SIZE}<span class="downloadSizeDetails">({$size.SIZE})</span>{/if}
39  </a>
40  {/foreach}
41</div>
Note: See TracBrowser for help on using the repository browser.