New programmer templates for the OPAC. Markup has been pared down, but structure...
[koha.git] / koha-tmpl / opac-tmpl / prog / en / opac-search.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" --><!-- TMPL_VAR NAME="LibraryName" --> Catalog -- Advanced Search
2 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
3 <!--TMPL_INCLUDE NAME="masthead_adv.inc" -->
4 <!--TMPL_INCLUDE NAME="navigation.inc" -->
5
6 <!-- CONTENT -->
7 <div id="main">
8 <form name="f" method="post" action="/cgi-bin/koha/opac-search.pl">
9 <h1>Search the Catalog</h1>
10
11                         <h3>Results:</h3>
12                         <p><label for="resultsperpage">Results per page:</label>
13                         <select name="resultsperpage" id="resultsperpage" size="1">
14                                 <option value="20">20</option>
15                                 <option value="50">50</option>
16                                 <option value="100">100</option>
17                         </select></p>
18                 <p><label for="orderby">Ordered by:</label>
19                         <select name="orderby" id="orderby" size="1">
20                                 <option value="biblio.title">Title</option>
21                                 <option value="biblio.author">Author</option>
22                                 <option value="biblioitems.dewey">Dewey</option>
23                                 <option value="biblioitems.publicationyear">Publication Year</option>
24                                 <option value="biblioitems.publishercode">Publisher</option>
25                         </select>
26                         <select name="desc_or_asc" size="1">
27                                 <option value="ASC">Ascending</option>
28                                 <option value="DESC">Descending</option>
29                 </select>
30                 </p>
31
32 <table>
33 <tr><th scope="row"><label for="keyword">Keyword</label></th><td><input type="hidden" name="op" value="do_search" />
34                         <input type="hidden" name="nbstatements" value="<!-- TMPL_VAR NAME="nbstatements" -->" />
35                 <input type="hidden" name="marclist" value="" />
36                         <input type="hidden" name="and_or" value="and" />
37                         <input type="hidden" name="excluding" value="" />
38                         <input type="hidden" name="operator" value="contains" />
39                         <input type="text" id="keyword" name="value" /></td></tr>
40 <tr><th scope="row"><label for="title">Title</label></th><td><input type="hidden" name="marclist" value="biblio.title" />
41                         <input type="hidden" name="and_or" value="and" />
42                         <input type="hidden" name="excluding" value="" />
43                         <input type="hidden" name="operator" value="contains" />
44                         <input type="text" id="title" name="value" /><!-- TMPL_UNLESS NAME="Disable_Dictionary" --><a href="javascript:Dopop('opac-dictionary.pl?marclist=biblio.title&amp;type=intranet&amp;index=1',1)"><strong>...</strong></a><!-- /TMPL_UNLESS --></td></tr>
45 <tr><th scope="row"><label for="author">Author</label></th><td><input type="hidden" name="marclist" value="biblio.author" />
46                         <input type="hidden" name="and_or" value="and" />
47                         <input type="hidden" name="excluding" value="" />
48                         <input type="hidden" name="operator" value="contains" />
49                         <input type="text" id="author" name="value" /><!-- TMPL_UNLESS NAME="Disable_Dictionary" --><a href="javascript:Dopop('opac-dictionary.pl?marclist=biblio.author&amp;type=intranet&amp;index=2',2)"><strong>...</strong></a><!-- /TMPL_UNLESS --></td></tr>
50 <tr><th scope="row"><label for="subject">Subject</label></th><td>                       
51                         <input type="hidden" name="marclist" value="bibliosubject.subject" />
52                         <input type="hidden" name="and_or" value="and" />
53                         <input type="hidden" name="excluding" value="" />
54                         <input type="hidden" name="operator" value="contains" />  
55                         <input type="text" id="subject" name="value" size="35" /><!-- TMPL_UNLESS NAME="Disable_Dictionary" --><a href="javascript:Dopop('opac-dictionary.pl?marclist=bibliosubject.subject&amp;type=intranet&amp;index=3',3)"><strong>...</strong></a><!-- /TMPL_UNLESS --></td></tr>
56 <tr><th scope="row"><label for="seriestitle">Series title</label></th><td>                      
57                         <input type="hidden" name="marclist" value="biblio.seriestitle" />
58                         <input type="hidden" name="and_or" value="and" />
59                         <input type="hidden" name="excluding" value="" />
60                         <input type="hidden" name="operator" value="contains" />
61                         <input type="text" id="seriestitle" name="value" size="35"/></td></tr>
62
63 <tr><th scope="row"><label for="itemtype">Format</label></th><td><input type="hidden" name="marclist" value="biblioitems.itemtype" />
64                         <input type="hidden" name="and_or" value="and" />
65                         <input type="hidden" name="excluding" value="" />
66                         <input type="hidden" name="operator" value="=" />
67                         <!-- TMPL_VAR name="CGIitemtype" --></td></tr>
68 <tr><th scope="row"><label for="branch">Location</label></th><td><input type="hidden" name="marclist" value="items.homebranch" />
69                                 <input type="hidden" name="and_or" value="and" />
70                                 <input type="hidden" name="excluding" value="" />
71                                 <input type="hidden" name="operator" value="=" />  
72                                 <!-- TMPL_VAR name="CGIbranch" --></td></tr>
73 </table>                        
74 <p><input type="submit" value="Search" /></p>
75 <table>
76 <caption>Other options:</caption>
77 <tr><th scope="row"><label for="barcode">Barcode</label></th><td>
78                                 <input type="hidden" name="marclist" value="items.barcode" />
79                                 <input type="hidden" name="and_or" value="and" />
80                                 <input type="hidden" name="excluding" value="" />
81                                 <input type="hidden" name="operator" value="=" />
82                                 <input type="text" id="barcode" name="value" size="14" maxlength="14" /></td></tr>
83 <tr><th scope="row"><label for="dewey">Call Number</label></th><td><input type="hidden" name="marclist" value="biblioitems.dewey" />
84                         <input type="hidden" name="and_or" value="and" />
85                         <input type="hidden" name="excluding" value="" />
86                         <input type="hidden" name="operator" value="start" />
87                         <input type="text" id="dewey" name="value" /></td></tr>
88 <tr><th scope="row"><label for="isbn">ISBN</label></th><td><input type="hidden" name="marclist" value="biblioitems.isbn" />
89                         <input type="hidden" name="and_or" value="and" />
90                         <input type="hidden" name="excluding" value="" />
91                         <input type="hidden" name="operator" value="start" />
92                         <input type="text" id="isbn" name="value" /></td></tr>
93 <tr><th scope="row"><label for="publisher">Publisher</label></th><td><input type="hidden" name="marclist" value="biblioitems.publishercode" />
94                         <input type="hidden" name="and_or" value="and" />
95                         <input type="hidden" name="excluding" value="" />
96                         <input type="hidden" name="operator" value="contains" />
97                         <input type="text" id="publisher" name="value" /></td></tr>
98 <tr><th scope="row"><label for="pubbetween">Published between</label></th><td><input type="hidden" name="marclist" value="biblioitems.publicationyear" />
99                         <input type="hidden" name="and_or" value="and" />
100                         <input type="hidden" name="excluding" value="" />
101                         <input type="hidden" name="operator" value=">=" />
102                         <input type="text" id="pubbetween" name="value" size="6" maxlength="4" /></td></tr>
103 <tr><th scope="row"><label for="puband">...and</label></th><td><input type="hidden" name="marclist" value="biblioitems.publicationyear" />
104                         <input type="hidden" name="and_or" value="and" />
105                         <input type="hidden" name="excluding" value="" />
106                         <input type="hidden" name="operator" value="<=" />
107                         <input type="text" id="puband" name="value" size="6" maxlength="4" /></td></tr>
108 </table>
109                 <p><input type="submit" value="Search" /></p>
110 </form>
111
112 <!-- Hide from NPL --><div class="content-block">
113 <h3>Recent acquisitions</h3>
114         <form action="/cgi-bin/koha/opac-search.pl">
115                 <p>
116                         <!-- TMPL_VAR name="CGIitemtype" --> acquired recently (the most recent being first)
117                         <input type="hidden" name="marclist" value="biblioitems.itemtype" />
118                         <input type="hidden" name="and_or" value="and" />
119                         <input type="hidden" name="excluding" value="" />
120                         <input type="hidden" name="operator" value="=" />
121                         <input type="hidden" name="op" value="do_search" />
122                         <input type="hidden" name="type" value="opac" />
123                         <input type="hidden" name="orderby" value="biblio.timestamp desc" />
124                         <input type="submit" value="Search" />
125                 </p>
126         </form>
127 </div><!-- /Hide from NPL -->
128 <script type="text/javascript">
129 function sql_update() {
130 document.f.sql.value="";
131         for (i=0 ; i<document.f.marclist.length ; i++) {
132                 if (document.f.value[i].value.length>0) {
133                         document.f.sql.value = document.f.sql.value+
134                                                                                 document.f.and_or[i].value + ' (' +
135                                                                                 document.f.excluding[i].value + ' ' +
136                                                                                 document.f.marclist[i].value + ' ' +
137                                                                                 document.f.operator[i].value + ' ' +
138                                                                                 '\''+document.f.value[i].value + '\') ';
139                 }
140         }
141 }
142
143 function AddStatement() {
144
145         document.forms[0].op.value="AddStatement";
146         document.f.submit();
147 }
148
149 function PopupSuggestion() {
150     var strQuery="";
151         for (i=0 ; i<document.f.marclist.length ; i++) {
152                 if (document.f.value[i].value.length>0) {
153                     strQuery += " "+document.f.value[i].value;
154                 }
155         }
156         newin=window.open("suggest.pl?Q="+strQuery,"Suggestions",'width=500,height=400,toolbar=false,scrollbars=yes');
157 }
158
159 </script>
160
161
162 </div>
163 <!-- TMPL_INCLUDE NAME="opac-bottom.inc" -->