5 [% USE AdditionalContents %]
6 [% PROCESS 'html_helpers.inc' %]
7 [% SET OpacLangSelectorMode = Koha.Preference('OpacLangSelectorMode') %]
8 [% SET OpacHeader = AdditionalContents.get( location => "opacheader", lang => lang, library => logged_in_user.branchcode || default_branch, blocktitle => 0 ) %]
9 [% SET OpacCustomSearch = AdditionalContents.get( location => "OpacCustomSearch", lang => lang, library => logged_in_user.branchcode || default_branch, blocktitle => 0 ) %]
10 [% SET OpacLoginInstructions = AdditionalContents.get( location => "OpacLoginInstructions", lang => lang, library => branchcode || default_branch ) %]
11 [% SET OpacMoreSearches = AdditionalContents.get( location => "OpacMoreSearches", lang => lang, library => branchcode || default_branch ) %]
13 <button id="scrolltocontent">Skip to main content</button>
15 <div id="header-region" class="noprint">
16 <nav class="navbar navbar-expand">
18 <a class="navbar-brand" href="/cgi-bin/koha/opac-main.pl">
19 [% IF ( LibraryNameTitle ) %]
20 [% LibraryNameTitle | html %]
26 [% IF ( Koha.Preference( 'opacbookbag' ) == 1 ) %]
27 <div id="cartDetails" class="cart-message">Your cart is empty.</div>
29 <ul id="cart-list-nav" class="navbar-nav">
30 [% IF ( Koha.Preference( 'opacbookbag' ) == 1 ) %]
31 <li class="nav-item js-show">
32 <a href="#" class="nav-link" title="Collect items you are interested in" id="cartmenulink" role="button">
33 <i id="carticon" class="fa fa-shopping-cart fa-icon-black" aria-hidden="true"></i> <span class="cartlabel">Cart</span> <span id="basketcount"></span>
37 <li class="divider-vertical"></li>
38 [% IF ( Koha.Preference( 'virtualshelves' ) == 1 ) %]
39 <li class="nav-item dropdown">
40 <a href="/cgi-bin/koha/opac-shelves.pl" title="Show lists" class="nav-link dropdown-toggle" id="listsmenu" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"
41 ><i class="fa fa-list fa-icon-black" aria-hidden="true"></i> <span class="listslabel">Lists</span>
43 <div aria-labelledby="listsmenu" role="menu" class="dropdown-menu">
44 [% IF some_public_shelves.count %]
45 <a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=1" tabindex="-1" role="menuitem"><strong>Public lists</strong></a>
46 [% SET number_of_public_shelves = 0 %]
47 [% FOREACH s IN some_public_shelves %]
48 <a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=view&shelfnumber=[% s.shelfnumber | uri %]&sortfield=[% s.sortfield | uri %]" tabindex="-1" role="menuitem">[% s.shelfname | html %]</a>
49 [% SET number_of_public_shelves = number_of_public_shelves + 1 %]
50 [% IF number_of_public_shelves >= 10 %][% LAST %][% END %]
52 [% IF some_public_shelves > 10 %]
53 <a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=1" tabindex="-1" role="menuitem">View all</a>
56 [% IF some_public_shelves.count > 0 %]
57 <div class="dropdown-divider"></div>
59 [% IF Koha.Preference( 'opacuserlogin' ) == 1 %]
60 <a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=0" tabindex="-1" role="menuitem"><strong>Your lists</strong></a>
61 [% IF loggedinusername %]
62 [% IF some_private_shelves.count %]
63 [% SET number_of_private_shelves = 0 %]
64 [% FOREACH s IN some_private_shelves %]
65 <a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=view&shelfnumber=[% s.shelfnumber | uri %]&sortfield=[% s.sortfield | uri %]" tabindex="-1" role="menuitem">[% s.shelfname | html %]</a>
66 [% SET number_of_private_shelves = number_of_private_shelves + 1 %]
67 [% IF number_of_private_shelves >= 10 %][% LAST %][% END %]
69 [% IF some_private_shelves > 10 %]
70 <a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=0" tabindex="-1" role="menuitem">View all</a>
73 <a class="dropdown-item disabled" href="#" tabindex="-1" role="menuitem">No private lists</a>
75 <a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=add_form" tabindex="-1" role="menuitem">New list</a>
77 <a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=add_form" tabindex="-1" role="menuitem">Log in to create your own lists</a>
78 [% END # / IF loggedinusername %]
79 [% END # / IF opacuserlogin %]
80 </div> <!-- / .dropdown-menu -->
81 </li> <!-- / .nav-item.dropdown -->
82 [% END # / IF virtualshelves %]
83 </ul> <!-- / .navbar-nav -->
85 [% IF Koha.Preference( 'opacuserlogin' ) == 1 || Koha.Preference( 'EnableOpacSearchHistory') || Koha.Preference( 'opaclanguagesdisplay' ) %]
86 [% IF ( Koha.Preference( 'opaclanguagesdisplay' ) ) %]
87 [% INCLUDE 'masthead-langmenu.inc' %]
89 <ul id="members" class="navbar-nav">
90 <li class="nav-item dropdown">
91 [% IF ( Koha.Preference( 'opacuserlogin' ) == 1 ) %]
92 [% IF ( loggedinusername ) %]
93 <a href="/cgi-bin/koha/opac-user.pl" class="dropdown-toggle" id="user-menu" data-toggle="dropdown" role="button">
94 <i class="fa fa-user fa-icon-black fa-fw" aria-hidden="true"></i>
95 <span class="userlabel">Welcome, [% INCLUDE 'patron-title.inc' patron = logged_in_user no_html = 1 %]</span>
97 <a tabindex="-1" role="menuitem" class="logout js-hide" href="/cgi-bin/koha/opac-main.pl?logout.x=1"><i class="fa fa-fw fa-sign-out" aria-hidden="true"></i> Log out</a>
99 [% IF Koha.Preference('casAuthentication') %]
100 [%# CAS authentication is too complicated for modal window %]
101 <a class="nav-link login-link" href="/cgi-bin/koha/opac-user.pl"><i class="fa fa-user fa-icon-black fa-fw" aria-hidden="true"></i> <span class="userlabel">Log in to your account</span></a>
102 [% ELSIF ( Koha.Preference('GoogleOpenIDConnect') == 1 ) %]
103 <a href="/cgi-bin/koha/svc/auth/googleopenidconnect" class="nav-link login-link loginModal-trigger"><i class="fa fa-user fa-icon-black fa-fw" aria-hidden="true"></i> <span class="userlabel">Log in to your account</span></a>
105 <a href="/cgi-bin/koha/opac-user.pl" class="nav-link login-link loginModal-trigger"><i class="fa fa-user fa-icon-black fa-fw" aria-hidden="true"></i> <span class="userlabel">Log in to your account</span></a>
110 [% IF ( Koha.Preference( 'opacuserlogin' ) == 1 && loggedinusername ) %]
111 <div aria-labelledby="user-menu" role="menu" class="dropdown-menu dropdown-menu-right">
112 <div id="loggedinuser-menu">
114 <a class="login-link" href="/cgi-bin/koha/opac-user.pl"><span class="loggedinusername" data-borrowernumber="[% logged_in_user.borrowernumber | html %]" data-branchcode="[% logged_in_user.branchcode | html %]" data-categorycode="[% logged_in_user.categorycode | html %]">Your account</span></a>
116 [% IF Koha.Preference( 'EnableOpacSearchHistory' ) %]
118 <a tabindex="-1" role="menuitem" class="login-link" href="/cgi-bin/koha/opac-search-history.pl" title="View your search history">Search history</a>
119 <span class="divider-vertical"></span>
120 <a class="clearsh" href="/cgi-bin/koha/opac-search-history.pl?action=delete" title="Delete your search history"><i class="fa fa-trash" aria-hidden="true"></i> Clear</a>
123 <a tabindex="-1" role="menuitem" class="logout" id="logout" href="/cgi-bin/koha/opac-main.pl?logout.x=1">Log out</a>
128 [% IF ( !Koha.Preference( 'opacuserlogin') || !loggedinusername ) %]
129 [% IF Koha.Preference( 'EnableOpacSearchHistory' ) %]
130 <li class="nav-item search_history">
131 <a class="nav-link login-link" href="/cgi-bin/koha/opac-search-history.pl" title="View your search history">Search history</a>
133 <li class="divider-vertical"></li>
134 <li class="nav-item">
135 <a class="nav-link logout clearsh" href="/cgi-bin/koha/opac-search-history.pl?action=delete" title="Delete your search history"><i class="fa fa-trash" aria-hidden="true"></i> Clear</a>
140 [% END # IF opacuserlogin || EnableOpacSearchHistory || opaclanguagesdisplay %]
141 </nav> <!-- /navbar -->
143 [% IF ( OpacHeader ) %]
144 <div class="container-fluid">
147 [% PROCESS koha_news_block news => OpacHeader %]
153 </div> <!-- / header-region -->
155 [% IF ( OpacPublic ) %]
156 <div class="container-fluid">
157 [% UNLESS ( advsearch ) %]
160 <div id="opac-main-search" class="mastheadsearch">
161 [% IF ( OpacCustomSearch ) %]
162 [% PROCESS koha_news_block news => OpacCustomSearch %]
164 <form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform">
165 <div class="form-row align-items-center">
166 <div class="col-sm-auto order-1 order-sm-1">
167 <label for="masthead_search"> Search
168 [% UNLESS ( Koha.Preference( 'OpacAddMastheadLibraryPulldown' ) == 1 ) %]
169 [% IF ( mylibraryfirst ) %]
170 (in [% Branches.GetName( mylibraryfirst ) | html %] only)
175 <div class="col-sm-auto order-2 order-sm-2">
176 <select name="idx" id="masthead_search" class="form-control">
178 <option selected="selected" value="">Library catalog</option>
180 <option value="">Library catalog</option>
183 <option selected="selected" value="ti">Title</option>
185 <option value="ti">Title</option>
188 <option selected="selected" value="au">Author</option>
190 <option value="au">Author</option>
193 <option selected="selected" value="su">Subject</option>
195 <option value="su">Subject</option>
198 <option selected="selected" value="nb">ISBN</option>
200 <option value="nb">ISBN</option>
203 <option selected="selected" value="ns">ISSN</option>
205 <option value="ns">ISSN</option>
208 <option selected="selected" value="se">Series</option>
210 <option value="se">Series</option>
212 [% IF ( Koha.Preference('OPACNumbersPreferPhrase') ) %]
213 [% IF ( ms_callnumcommaphr ) %]
214 <option selected="selected" value="callnum,phr">Call number</option>
216 <option value="callnum,phr">Call number</option>
217 [% END #/ms_callnumcommaphr %]
219 [% IF ( ms_callnum ) %]
220 <option selected="selected" value="callnum">Call number</option>
222 <option value="callnum">Call number</option>
223 [% END # /ms_callnum %]
224 [% END # /IF OPACNumbersPreferPhrase %]
226 </div> <!-- /.col-sm-auto -->
228 <div class="col order-4 order-sm-3">
229 [% IF ( ms_value ) %]
230 <input type="text" title="Type search term" class="transl1 form-control" id="translControl1" name="q" value="[% ms_value | html %]" /><span id="translControl"></span>
232 <input type="text" title="Type search term" class="transl1 form-control" id="translControl1" name="q" /><span id="translControl"></span>
233 [% END # /ms_value %]
234 </div> <!-- /.col -->
236 [% IF ( Koha.Preference( 'OpacAddMastheadLibraryPulldown' ) == 1 ) %]
237 <div class="col-sm col-md-3 col-lg-2 order-3 order-sm-4">
238 <select name="limit" id="select_library" class="form-control">
239 <option value="">All libraries</option>
241 [% IF LibrarySearchGroups %]<optgroup label="Libraries">[% END %]
243 [% FOREACH library IN Branches.all( selected => opac_name ) %]
244 [% IF library.selected %]
245 <option selected="selected" value="branch:[% library.branchcode | html %]">[% library.branchname | html %]</option>
247 <option value="branch:[% library.branchcode | html %]">[% library.branchname | html %]</option>
251 [% IF LibrarySearchGroups %]
253 <optgroup label="Groups">
254 [% FOREACH lsg IN LibrarySearchGroups %]
255 [% IF 'multibranchlimit-' _ lsg.id == opac_name || lsg.id == opac_name %]
256 <option selected="selected" value="multibranchlimit:[% lsg.id | html %]">[% lsg.title | html %]</option>
258 <option value="multibranchlimit:[% lsg.id | html %]">[% lsg.title | html %]</option>
259 [% END # / bc.selected %]
262 [% END # / BranchCategoriesLoop %]
263 </select> <!-- /#select_library -->
264 </div> <!-- /.col-sm-auto -->
265 <div class="col-sm-auto order-5">
266 <button type="submit" id="searchsubmit" class="btn btn-primary">Go</button>
269 [% IF ( opac_limit_override ) %]
270 [% IF ( opac_search_limit ) %]
271 [% IF ( multibranchlimit = opac_search_limit.match( 'branch:multibranchlimit-(\d+)' ) ) %]
272 <input name="limit" value="multibranchlimit:[% multibranchlimit.0 | html %]" type="hidden" />
274 <input name="limit" value="[% opac_search_limit | html %]" type="hidden" />
278 [% IF ( mylibraryfirst ) %]
279 <input name="limit" value="branch:[% mylibraryfirst | html %]" type="hidden" />
281 [% END # / opac_limit_override %]
282 <div class="order-5 col-sm-auto">
283 <button type="submit" id="searchsubmit" class="btn btn-primary">Go</button>
285 [% END # / OpacAddMastheadLibraryPulldown %]
286 </div> <!-- /.form-row -->
287 <input type="hidden" name="weight_search" value="1">
289 [% END # / ( OpacCustomSearch ) %]
290 </div><!-- /#opac-main-search -->
291 </div> <!-- /.col -->
292 </div> <!-- /.row -->
293 [% END # / UNLESS advsearch %]
296 <ul class="nav" id="moresearches">
297 <li class="nav-item">
298 <a href="/cgi-bin/koha/opac-search.pl">Advanced search</a>
300 [% IF ( Koha.Preference( 'UseCourseReserves' ) == 1 ) %]
301 <li class="nav-item">
302 <a href="/cgi-bin/koha/opac-course-reserves.pl">Course reserves</a>
305 [% IF Koha.Preference( 'OpacBrowser' ) == 1 %]
306 <li class="nav-item">
307 <a href="/cgi-bin/koha/opac-browser.pl">Browse by hierarchy</a>
310 [% IF Koha.Preference( 'OpacAuthorities' ) == 1 %]
311 <li class="nav-item">
312 <a href="/cgi-bin/koha/opac-authorities-home.pl">Authority search</a>
315 [% IF ( ( Koha.Preference( 'opacuserlogin' ) == 1 ) && ( Koha.Preference( 'OPACComments' ) == 1 ) && ( Koha.Preference( 'OpacShowRecentComments' ) == 1 ) ) %]
316 <li class="nav-item">
317 <a href="/cgi-bin/koha/opac-showreviews.pl">Recent comments</a>
320 [% IF Koha.Preference( 'TagsEnabled' ) == 1 %]
321 <li class="nav-item">
322 <a href="/cgi-bin/koha/opac-tags.pl">Tag cloud</a>
325 [% IF Koha.Preference( 'OpacCloud' ) == 1 %]
326 <li class="nav-item">
327 <a href="/cgi-bin/koha/opac-tags_subject.pl">Subject cloud</a>
330 [% IF Koha.Preference( 'OpacTopissue' ) == 1 %]
331 <li class="nav-item">
332 <a href="/cgi-bin/koha/opac-topissues.pl">Most popular</a>
335 [% IF Koha.Preference('SearchEngine') == 'Elasticsearch' && Koha.Preference( 'OpacBrowseSearch' ) == 1 %]
336 <li class="nav-item">
337 <a href="/cgi-bin/koha/opac-browse.pl">Browse search</a>
340 [% IF Koha.Preference( 'suggestion' ) == 1 %]
341 [% IF Koha.Preference( 'AnonSuggestions' ) == 1 || Koha.Preference( 'OPACViewOthersSuggestions' ) == 1 %]
342 <li class="nav-item">
343 <a href="/cgi-bin/koha/opac-suggestions.pl?suggested_by_anyone=1">Purchase suggestions</a>
347 <li class="nav-item">
348 <a id="library_page" href="/cgi-bin/koha/opac-library.pl">
349 [% IF ( singleBranchMode ) %]
356 [% PROCESS koha_news_block news => OpacMoreSearches %]
357 </ul> <!-- /.nav#moresearches -->
358 </div> <!-- /.row -->
359 </div> <!-- /.container-fluid -->
360 [% END # / OpacPublic %]
362 <!-- Login form hidden by default, used for modal window -->
363 <div id="loginModal" class="modal" tabindex="-1" role="dialog" aria-labelledby="modalLoginLabel" aria-hidden="true">
364 <div class="modal-dialog">
365 <div class="modal-content">
366 <div class="modal-header">
367 <h2 class="modal-title" id="modalLoginLabel">Log in to your account</h2>
368 <button type="button" class="closebtn" data-dismiss="modal" aria-label="Close">
369 <span aria-hidden="true">×</span>
372 <form action="/cgi-bin/koha/opac-user.pl" method="post" name="auth" id="modalAuth">
373 <input type="hidden" name="has-search-query" id="has-search-query" value="" />
374 <div class="modal-body">
375 [% IF ( Koha.Preference('GoogleOpenIDConnect') == 1 ) %]
376 <a href="/cgi-bin/koha/svc/auth/googleopenidconnect" class="btn btn-light" id="openid_connect"><i class="fa fa-google" aria-hidden="true"></i> Log in with Google</a>
377 <p>If you do not have a Google account, but do have a local account, you can still log in: </p>
378 [% END # /IF GoogleOpenIDConnect %]
379 [% IF ( shibbolethAuthentication ) %]
380 [% IF ( invalidShibLogin ) %]
381 <!-- This is what is displayed if shibboleth login has failed to match a koha user -->
382 <div class="alert alert-info">
383 <p>Sorry, your Shibboleth identity does not match a valid library identity. If you have a local login, you may use that below.</p>
386 <h3>Shibboleth login</h3>
387 <p><a href="[% shibbolethLoginUrl | $raw %]">Log in using a Shibboleth account</a>.</p>
388 [% UNLESS Koha.Preference('opacShibOnly') %]
393 [% UNLESS Koha.Preference('opacShibOnly') %]
394 <input type="hidden" name="koha_login_context" value="opac" />
395 <fieldset class="brief">
396 <label for="muserid">Login:</label><input type="text" id="muserid" name="userid" autocomplete="off" />
397 <label for="mpassword">Password:</label><input type="password" id="mpassword" name="password" autocomplete="off" />
398 <fieldset class="action">
399 <input type="submit" class="btn btn-primary" value="Log in" />
401 [% IF OpacLoginInstructions %]
402 <div id="nologininstructions-modal" class="nologininstructions">
403 [% PROCESS koha_news_block news => OpacLoginInstructions %]
406 [% IF Koha.Preference('OpacPasswordChange') && Categories.can_any_reset_password %]
407 <div id="forgotpassword-modal" class="forgotpassword">
408 <a href="/cgi-bin/koha/opac-password-recovery.pl">Forgot your password?</a>
411 [% IF PatronSelfRegistration && PatronSelfRegistrationDefaultCategory %]
412 <div id="patronregistration-modal" class="patronregistration">
413 <p>Don't have an account? <a href="/cgi-bin/koha/opac-memberentry.pl">Register here.</a></p>
419 </form> <!-- /#auth -->
420 </div> <!-- /.modal-content -->
421 </div> <!-- /.modal-dialog -->
422 </div> <!-- /#modalAuth -->