source: trunk/themes/default/template/search.tpl @ 7975

Last change on this file since 7975 was 7975, checked in by rvelices, 13 years ago

new template features: combine_script, footer_script and get_combined_scripts
migrated public templates only; need more code doc

  • Property svn:eol-style set to LF
File size: 5.5 KB
Line 
1
2{* Example of resizeable *}
3
4{include file='include/resize.inc.tpl'}
5
6
7{* Example of datepicker *}
8
9{include file='include/datepicker.inc.tpl'}
10
11{footer_script}{literal}
12  pwg_initialization_datepicker("#start_day", "#start_month", "#start_year", "#start_linked_date", null, null, "#end_linked_date");
13  pwg_initialization_datepicker("#end_day", "#end_month", "#end_year", "#end_linked_date", null, "#start_linked_date", null);
14 jQuery().ready(function(){ $(".date_today").hide(); });
15{/literal}{/footer_script}
16
17
18<div id="content" class="content">
19
20  <div class="titrePage">
21    <ul class="categoryActions">
22                        {combine_script id='core.scripts' load='async' path='themes/default/js/scripts.js'}
23      <li><a href="{$U_HELP}" onclick="popuphelp(this.href); return false;" title="{'Help'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/help.png" class="button" alt="(?)"></a></li>
24      <li><a href="{$U_HOME}" title="{'Home'|@translate}" rel="Home"><img src="{$ROOT_URL}{$themeconf.icon_dir}/home.png" class="button" alt="{'Home'|@translate}"></a></li>
25    </ul>
26    <h2>{'Search'|@translate}</h2>
27  </div>
28
29{if isset($errors) }
30<div class="errors">
31  <ul>
32    {foreach from=$errors item=error}
33    <li>{$error}</li>
34    {/foreach}
35  </ul>
36</div>
37{/if}
38
39<form class="filter" method="post" name="search" action="{$F_SEARCH_ACTION}">
40<fieldset>
41  <legend>{'Filter'|@translate}</legend>
42  <label>{'Search for words'|@translate}
43    <input type="text" style="width: 300px" name="search_allwords" size="30">
44  </label>
45  <ul>
46    <li><label>
47      <input type="radio" name="mode" value="AND" checked="checked">{'Search for all terms'|@translate}
48    </label></li>
49    <li><label>
50      <input type="radio" name="mode" value="OR">{'Search for any terms'|@translate}
51    </label></li>
52  </ul>
53  <label>{'Search for Author'|@translate}
54    <input type="text" style="width: 300px" name="search_author" size="30">
55  </label>
56</fieldset>
57
58{if isset($TAG_SELECTION)}
59<fieldset>
60  <legend>{'Search tags'|@translate}</legend>
61  {$TAG_SELECTION}
62  <label><span><input type="radio" name="tag_mode" value="AND" checked="checked"> {'All tags'|@translate}</span></label>
63  <label><span><input type="radio" name="tag_mode" value="OR"> {'Any tag'|@translate}</span></label>
64</fieldset>
65{/if}
66
67<fieldset>
68  <legend>{'Search by Date'|@translate}</legend>
69  <ul>
70    <li><label>{'Kind of date'|@translate}</label></li>
71    <li><label>
72      <input type="radio" name="date_type" value="date_creation" checked="checked">{'Creation date'|@translate}
73    </label></li>
74    <li><label>
75      <input type="radio" name="date_type" value="date_available">{'Post date'|@translate}
76    </label></li>
77  </ul>
78  <ul>
79    <li><label>{'Date'|@translate}</label></li>
80    <li>
81      <select id="start_day" name="start_day">
82          <option value="0">--</option>
83        {section name=day start=1 loop=32}
84          <option value="{$smarty.section.day.index}" {if $smarty.section.day.index==$START_DAY_SELECTED}selected="selected"{/if}>{$smarty.section.day.index}</option>
85        {/section}
86      </select>
87      <select id="start_month" name="start_month">
88        {html_options options=$month_list selected=$START_MONTH_SELECTED}
89      </select>
90      <input id="start_year" name="start_year" type="text" size="4" maxlength="4" >
91      <input id="start_linked_date" name="start_linked_date" type="hidden" size="10" disabled="disabled">
92    </li>
93    <li>
94      <a class="date_today" href="#" onClick="document.search.start_day.value={$smarty.now|date_format:"%d"};document.search.start_month.value={$smarty.now|date_format:"%m"};document.search.start_year.value={$smarty.now|date_format:"%Y"};return false;">{'today'|@translate}</a>
95    </li>
96  </ul>
97  <ul>
98    <li><label>{'End-Date'|@translate}</label></li>
99    <li>
100      <select id="end_day" name="end_day">
101          <option value="0">--</option>
102        {section name=day start=1 loop=32}
103          <option value="{$smarty.section.day.index}" {if $smarty.section.day.index==$END_DAY_SELECTED}selected="selected"{/if}>{$smarty.section.day.index}</option>
104        {/section}
105      </select>
106      <select id="end_month" name="end_month">
107        {html_options options=$month_list selected=$END_MONTH_SELECTED}
108      </select>
109      <input id="end_year" name="end_year" type="text" size="4" maxlength="4" >
110      <input id="end_linked_date" name="end_linked_date" type="hidden" size="10" disabled="disabled">
111    </li>
112    <li>
113      <a class="date_today" href="#" onClick="document.search.end_day.value={$smarty.now|date_format:"%d"};document.search.end_month.value={$smarty.now|date_format:"%m"};document.search.end_year.value={$smarty.now|date_format:"%Y"};return false;">{'today'|@translate}</a>
114    </li>
115  </ul>
116</fieldset>
117
118<fieldset>
119  <legend>{'Search Options'|@translate}</legend>
120  <label>{'Search in albums'|@translate}
121    <select class="categoryList" name="cat[]" multiple="multiple" >
122      {html_options options=$category_options selected=$category_options_selected}
123    </select>
124  </label>
125  <ul>
126    <li><label>{'Search in sub-albums'|@translate}</label></li>
127    <li><label>
128      <input type="radio" name="subcats-included" value="1" checked="checked">{'Yes'|@translate}
129    </label></li>
130    <li><label>
131      <input type="radio" name="subcats-included" value="0">{'No'|@translate}
132    </label></li>
133  </ul>
134</fieldset>
135<p>
136  <input class="submit" type="submit" name="submit" value="{'Submit'|@translate}">
137  <input class="submit" type="reset" value="{'Reset'|@translate}">
138</p>
139</form>
140
141<script type="text/javascript"><!--
142document.search.search_allwords.focus();
143//--></script>
144
145</div> <!-- content -->
Note: See TracBrowser for help on using the repository browser.