From 721a51340ec690b484638b5aa35cd33f08d0fc1e Mon Sep 17 00:00:00 2001 From: Srikanth Dhondi <srikanth@catalyst.net.nz> Date: Tue, 30 Oct 2012 11:17:52 +1300 Subject: [PATCH] bug 8712 - adding 'and' label for options in advanced search with fewer options Content-Type: text/plain; charset=utf-8 The "and" label not only improves the accessibility but also gives the user an idea that the operation between multiple search fields is a boolean "AND" by default. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Actually only adds a label and an id to the select. Note that the boxes do not exactly align anymore now (with fewer options). --- .../opac-tmpl/prog/en/modules/opac-advsearch.tt | 22 +++++++++++++------ 1 files changed, 15 insertions(+), 7 deletions(-) diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-advsearch.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-advsearch.tt index 8f763d1..aed3ed1 100644 --- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-advsearch.tt +++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-advsearch.tt @@ -56,15 +56,23 @@ <p> [% IF ( expanded_options ) %] [% IF ( search_box.boolean ) %] - <select name="op"> - <option value="and" selected="selected">and</option> - <option value="or">or</option> - <option value="not">not</option> - </select> + <select name="op"> + <option value="and" selected="selected">and</option> + <option value="or">or</option> + <option value="not">not</option> + </select> + [% END %] + [% ELSE %] + <label for="search-field_[% loop.index %]"> + [% IF loop.index == 0 %] + + [% ELSE %] + and + [% END %] + </label> [% END %] - [% END %] [% IF ( expanded_options ) %][% left_content %][% END %] - <select name="idx"> + <select name="idx" id="search-field_[% loop.index %]"> <option value="kw">Keyword</option> <option value="su,wrdl">Subject</option> [% IF ( expanded_options ) %] -- 1.7.7.6