]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/src/templates/opac/parts/searchbar.tt2
Read STDIN up to record separator then stop
[Evergreen.git] / Open-ILS / src / templates / opac / parts / searchbar.tt2
1 [% PROCESS "opac/parts/org_selector.tt2" %]
2 <div id="search-box">    
3     [% UNLESS took_care_of_form -%]
4     <form action="[% ctx.opac_root %]/results" method="GET">
5     [%- END %]
6     <table cellpadding="0" cellspacing="10" border="0">
7         <tr>
8             <td colspan="3">
9                 <span class="search_catalog_lbl">[% l('Search the Catalog') %]</span>
10                 <a href="[% ctx.opac_root %]/advanced"
11                     id="home_adv_search_link"><span
12                     class="adv_search_font">[% l('Advanced Search') %]</span></a>
13             </td>
14         </tr>
15         <tr>
16             [% IF is_advanced || is_special %]
17             <td colspan="2">
18                 <input type="hidden" name="_adv" value="1" />
19             [% ELSE %]
20             <td>
21             [% INCLUDE "opac/parts/qtype_selector.tt2" %]
22             </td>
23             [% END %]
24             [% IF ctx.processed_search_query OR (NOT is_advanced AND NOT is_special) %]
25             <td>
26                 <div id="search_box_wrapper">
27                     <!-- Note: when common browsers support HTML5 placeholder text, we can remove the JS -->
28                     <input type="text" id="search_box" name="query" value="[% is_advanced ? ctx.processed_search_query : CGI.param('query') || l("Search Keyword") | html %]"
29                         [% IF is_advanced %]style="width: 450px"[% END %]
30                         onfocus="if (this.value=='[% l("Search Keyword") %]'){this.value='';this.style.color='#000';}"
31                         onblur="if (this.value==''){this.value='[% l("Search Keyword") %]';this.style.color='#999';}"
32                         x-webkit-speech />
33                 </div>
34                 <input name='page' type='hidden' value="0" />
35             </td>
36             <td valign="top">
37                 <div class="pos-abs">
38                     <div class="opac-auto-143">
39                         <input id='search-submit-go' type="submit" value="[% l('Search') %]" alt="[% l('Search') %]" class="opac-button"
40                             onclick='setTimeout(function(){$("search-submit-spinner").className=""; $("search-submit-go").className="hidden"}, 2000)'/>
41                         <img id='search-submit-spinner' src='/opac/images/progressbar_green.gif' style='height:16px;width:16px;' class='hidden' alt=''/>
42                     </div>
43                 </div>
44             </td>
45             [% END %]
46         </tr>
47         [% UNLESS is_advanced OR is_special %]
48         <tr>
49             <td>
50                 [% INCLUDE "opac/parts/coded_value_selector.tt2" attr=["mattype", "item_type"] none_ok=1 none_label=l('All Formats') %]
51             </td>
52             <td>
53                 <span>
54                     [% PROCESS build_org_selector name='loc' value=CGI.param('loc') %]
55                 </span>
56             </td>
57         </tr>
58         [% END %]
59     </table>
60     [% UNLESS took_care_of_form %]</form>[% END %]
61     [% IF (is_advanced AND NOT is_special) AND CGI.param('qtype') %]
62     <div class="opac-auto-102">
63         [ <a href="[% mkurl(ctx.opac_root _ '/advanced') %]">[%
64             l('Click to Refine Your Original Search')
65         %]</a> ]
66     </div>
67     [% END %]
68     <!--
69     <div id="breadcrumb">
70         <a href="[% ctx.opac_root %]/home">[% l('Catalog Home') %]</a> &gt;
71     </div>
72     -->
73     <div class="clear-both"></div>
74 </div>