From 2eab6069700787e0e7746bde544352bc21f1cf4a Mon Sep 17 00:00:00 2001 From: rvelices Date: Tue, 18 Jan 2011 21:12:42 +0000 Subject: - picture page compacts the output html using smarty strip - decrease the default number of tags showable in the menubar git-svn-id: http://piwigo.org/svn/trunk@8757 68402e56-0260-453c-a942-63ccdbb3a9ee --- include/config_default.inc.php | 2 +- themes/default/template/picture.tpl | 36 ++++++++--------- themes/default/template/picture_nav_buttons.tpl | 51 ++++++++++++------------- 3 files changed, 44 insertions(+), 45 deletions(-) diff --git a/include/config_default.inc.php b/include/config_default.inc.php index 1249113a8..02a595f86 100644 --- a/include/config_default.inc.php +++ b/include/config_default.inc.php @@ -601,7 +601,7 @@ $conf['full_tag_cloud_items_number'] = 200; // menubar_tag_cloud_items_number: number of tags to show in the tag // cloud in the menubar. Only the most represented tags will be shown -$conf['menubar_tag_cloud_items_number'] = 100; +$conf['menubar_tag_cloud_items_number'] = 20; // content_tag_cloud_items_number: number of related tags to show in the tag // cloud on the content page, when the current section is not a set of diff --git a/themes/default/template/picture.tpl b/themes/default/template/picture.tpl index 0e479db69..0937489cf 100644 --- a/themes/default/template/picture.tpl +++ b/themes/default/template/picture.tpl @@ -35,38 +35,38 @@
-{if isset($U_SLIDESHOW_START)} +{strip}{if isset($U_SLIDESHOW_START)}  {'slideshow'|@translate} -{/if} -{if isset($U_METADATA)} +{/if}{/strip} +{strip}{if isset($U_METADATA)}  {'Show file metadata'|@translate} -{/if} -{if isset($current.U_DOWNLOAD)} +{/if}{/strip} +{strip}{if isset($current.U_DOWNLOAD)}  {'download'|@translate} -{/if} +{/if}{/strip} {if isset($PLUGIN_PICTURE_ACTIONS)}{$PLUGIN_PICTURE_ACTIONS}{/if} -{if isset($favorite)} +{strip}{if isset($favorite)}  {'Favorites'|@translate} -{/if} -{if isset($U_SET_AS_REPRESENTATIVE)} +{/if}{/strip} +{strip}{if isset($U_SET_AS_REPRESENTATIVE)}  {'representative'|@translate} -{/if} -{if isset($U_ADMIN)} +{/if}{/strip} +{strip}{if isset($U_ADMIN)}  {'edit'|@translate} -{/if} -{if isset($U_CADDIE)}{*caddie management BEGIN*} +{/if}{/strip} +{strip}{if isset($U_CADDIE)}{*caddie management BEGIN*} {footer_script} {literal}function addToCadie(aElement, rootUrl, id) { @@ -85,11 +85,11 @@ y.callService(  {'caddie'|@translate} -{/if}{*caddie management END*} +{/if}{/strip}{*caddie management END*}
{include file='picture_nav_buttons.tpl'|@get_extent:'picture_nav_buttons'} -
+{**}
{$ELEMENT_CONTENT} @@ -120,6 +120,7 @@ y.callService( {/if} +{strip} {if $display_info.author} @@ -216,7 +217,7 @@ y.callService( {/if} {/foreach} - {combine_script id='core.scripts' load='async' path='themes/default/js/scripts.js'} + {strip}{combine_script id='core.scripts' load='async' path='themes/default/js/scripts.js'} {combine_script id='rating' load='async' require='core.scripts' path='themes/default/js/rating.js'} {footer_script} var _pwgRatingAutoQueue = _pwgRatingAutoQueue||[]; @@ -224,6 +225,7 @@ y.callService( updateRateText: "{'Update your rating'|@translate|@escape:'javascript'}", updateRateElement: document.getElementById("updateRate"), ratingSummaryText: "{'%.2f (rated %d times)'|@translate|@escape:'javascript'}", ratingSummaryElement: document.getElementById("ratingSummary"){rdelim} ); {/footer_script} + {/strip} @@ -257,7 +259,7 @@ y.callService( {/if} - +{/strip}
{'Author'|@translate}
{if isset($metadata)} diff --git a/themes/default/template/picture_nav_buttons.tpl b/themes/default/template/picture_nav_buttons.tpl index 1a0e2c315..a3b9547aa 100644 --- a/themes/default/template/picture_nav_buttons.tpl +++ b/themes/default/template/picture_nav_buttons.tpl @@ -30,7 +30,7 @@  {'Not repeat the slideshow'|@translate} {/if} -{if isset($first)} +{strip}{if isset($first)}  {'First'|@translate} @@ -38,8 +38,8 @@  {'First'|@translate} -{/if} -{if isset($previous)} +{/if}{/strip} +{strip}{if isset($previous)}  {'Previous'|@translate} @@ -47,7 +47,7 @@  {'Previous'|@translate} -{/if} +{/if}{/strip} {if isset($slideshow.U_START_PLAY)}  {'Play of slideshow'|@translate} @@ -58,12 +58,12 @@  {'Pause of slideshow'|@translate} {/if} -{if isset($U_UP) and !isset($slideshow)} +{strip}{if isset($U_UP) and !isset($slideshow)}  {'Thumbnails'|@translate} -{/if} -{if isset($next)} +{/if}{/strip} +{strip}{if isset($next)}  {'Next'|@translate} @@ -71,8 +71,8 @@  {'Next'|@translate} -{/if} -{if isset($last)} +{/if}{/strip} +{strip}{if isset($last)} {'Last'|@translate} @@ -80,45 +80,42 @@  {'Last'|@translate} -{/if} +{/if}{/strip} {/if}
- -{footer_script}{literal} -document.onkeydown = function(e) -{ +{strip} +{footer_script} +document.onkeydown = function(e){ldelim} e=e||window.event; if (e.altKey) return true; - var target = e.target||e.srcElement; - if (target && target.type) return true; //an input editable element - var keyCode = e.keyCode||e.which; - var docElem = document.documentElement; - var url; - switch(keyCode) { -{/literal} + var target=e.target||e.srcElement; + if (target && target.type) return true;{* an input editable element *} + var keyCode=e.keyCode||e.which, docElem=document.documentElement, url; + switch(keyCode){ldelim} {if isset($next)} - case 63235: case 39: if (e.ctrlKey || docElem.scrollLeft==docElem.scrollWidth-docElem.clientWidth)url="{$next.U_IMG}"; break; + case 63235: case 39: if (e.ctrlKey || docElem.scrollLeft==docElem.scrollWidth-docElem.clientWidth)url="{$next.U_IMG}"; break; {/if} {if isset($previous)} case 63234: case 37: if (e.ctrlKey || docElem.scrollLeft==0)url="{$previous.U_IMG}"; break; {/if} {if isset($first)} - /*Home*/case 36: if (e.ctrlKey)url="{$first.U_IMG}"; break; + {* Home *}case 36: if (e.ctrlKey)url="{$first.U_IMG}"; break; {/if} {if isset($last)} - /*End*/case 35: if (e.ctrlKey)url="{$last.U_IMG}"; break; + {* End *}case 35: if (e.ctrlKey)url="{$last.U_IMG}"; break; {/if} {if isset($U_UP) and !isset($slideshow)} - /*Up*/case 38: if (e.ctrlKey)url="{$U_UP}"; break; + {* Up *}case 38: if (e.ctrlKey)url="{$U_UP}"; break; {/if} {if isset($slideshow.U_START_PLAY)} - /*Pause*/case 32: url="{$slideshow.U_START_PLAY}"; break; + {* Pause *}case 32: url="{$slideshow.U_START_PLAY}"; break; {/if} {if isset($slideshow.U_STOP_PLAY)} - /*Play*/case 32: url="{$slideshow.U_STOP_PLAY}"; break; + {* Play *}case 32: url="{$slideshow.U_STOP_PLAY}"; break; {/if} } if (url) {ldelim}window.location=url.replace("&","&"); return false;} return true; } {/footer_script} +{/strip} \ No newline at end of file -- cgit v1.2.3