aboutsummaryrefslogtreecommitdiffstats
path: root/template/yoga/menubar_menu.tpl
diff options
context:
space:
mode:
authorgrum <grum@piwigo.org>2008-10-26 19:10:18 +0000
committergrum <grum@piwigo.org>2008-10-26 19:10:18 +0000
commite9e57ab5c886e5dcb9e7872bfb13da4c38b34249 (patch)
tree07ded30b94b640aa14b2936aa86a2e665cc4d62b /template/yoga/menubar_menu.tpl
parentabe030444b21dd919ef63da32b4aac09a8c14729 (diff)
menu item "quicksearch" will be displayed only if a $block->data is set (like
other menu items) git-svn-id: http://piwigo.org/svn/trunk@2810 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'template/yoga/menubar_menu.tpl')
-rw-r--r--template/yoga/menubar_menu.tpl14
1 files changed, 8 insertions, 6 deletions
diff --git a/template/yoga/menubar_menu.tpl b/template/yoga/menubar_menu.tpl
index c16fae690..16c02f618 100644
--- a/template/yoga/menubar_menu.tpl
+++ b/template/yoga/menubar_menu.tpl
@@ -1,11 +1,13 @@
<dt>{'title_menu'|@translate}</dt>
<dd>
- <form action="{$ROOT_URL}qsearch.php" method="get" id="quicksearch" onsubmit="return this.q.value!='' && this.q.value!=qsearch_prompt;">
- <p style="margin:0;padding:0"{*this <p> is for html validation only - does not affect positioning*}>
- <input type="text" name="q" id="qsearchInput" onfocus="if (value==qsearch_prompt) value='';" onblur="if (value=='') value=qsearch_prompt;" style="width:90%"/>
- </p>
- </form>
- <script type="text/javascript">var qsearch_prompt="{'qsearch'|@translate|@escape:'javascript'}"; document.getElementById('qsearchInput').value=qsearch_prompt;</script>
+ {if isset($block->data.qsearch) and $block->data.qsearch=="yes"}
+ <form action="{$ROOT_URL}qsearch.php" method="get" id="quicksearch" onsubmit="return this.q.value!='' && this.q.value!=qsearch_prompt;">
+ <p style="margin:0;padding:0"{*this <p> is for html validation only - does not affect positioning*}>
+ <input type="text" name="q" id="qsearchInput" onfocus="if (value==qsearch_prompt) value='';" onblur="if (value=='') value=qsearch_prompt;" style="width:90%"/>
+ </p>
+ </form>
+ <script type="text/javascript">var qsearch_prompt="{'qsearch'|@translate|@escape:'javascript'}"; document.getElementById('qsearchInput').value=qsearch_prompt;</script>
+ {/if}
<ul>
{foreach from=$block->data item=link}