Jumpng checkbox selections in Advanced Search
The selected checkbox for "Limit to any of the following" in Advanced mode jump around when users navigate to the page by using the "back button". Their initial checkbox selections always jump six boxes down in our catalog. Example: <http://man.waldo.kohalibrary.com/cgi-bin/koha/opac-search.pl?expanded_options=1> In Advanced check the limit box for Curriculum Collection Type in a keyword. Hit Search. After viewing result page, hit back button or backspace. Now, the checkbox for Curriculum Collection is blank, but the one for Floor 4 is checked. It seems that if you search the public catalog in Advanced Search mode and choose any one of the first 11 Collection Codes listed under "Limit to any of the following", do a search and return to this Advanced Search, a new code will be selected. This may have something to do with the way our user interface is configured. I don't think it is happening in other LLEK catalogs. The checkboxes always jump 6 spaces. Since we have the last five codes set to be invisible to users, the "jumping" only occurs with the first 11 choices. This is a little confusing. Users who do not re-examine the checkboxes carefully not realize that they are now doing a search with a different limit. I would prefer that users who return to the Advanced Search screen using "back" to either find no checkbox limit selected or else find the same checkbox selected that they used for their search. Either of those behaviors would make sense, but the one where there is a new limit that seems to be selected by the system itself is confusing. When we first got set up with Koha, somone with Liblime helped us set up some javascript in Advanced Search that hides some of our CCODES from patrons. So I strongly suspect this his may be something we can change ourselves in the Admin settings, but I do not know how to do it. Can someone help me with this? We're using LLEK, but I suspect that this particular problem has to do with the customization that was done with our user interface for the Advanced Search page rather than a LLEK feature per se. Advance thanks. -- Stacy Pober Information Alchemist Manhattan College Library Riverdale, NY 10471 stacy.pober@manhattan.edu
* Stacy Pober (stacy.pober@manhattan.edu) wrote:
The selected checkbox for "Limit to any of the following" in Advanced mode jump around when users navigate to the page by using the "back button". Their initial checkbox selections always jump six boxes down in our catalog.
Example: <http://man.waldo.kohalibrary.com/cgi-bin/koha/opac-search.pl?expanded_options=1>
In Advanced check the limit box for Curriculum Collection Type in a keyword. Hit Search.
After viewing result page, hit back button or backspace.
Now, the checkbox for Curriculum Collection is blank, but the one for Floor 4 is checked.
Hi Stacy What browser are you using? Interestingly this behaviour doesn't happen in chromium (chrome) but does in firefox. There is this chunk of javascript set up. Which is suspect is the culprit //<![CDATA[ $(document).ready(function(){ $("#moresearches a[href*=opac-search]").remove(); $("#moresearches").prepend("<a href=\"/cgi-bin/koha/opac-main.pl\">Basic Search</a> | <a href=\"/cgi-bin/koha/opac-search.pl?expanded_options=1\">Advanced Search</a> "); $("#subtypes").appendTo("#pubrange"); $("#itype-19").parent().html(" "); $("#booleansearch fieldset").eq(0).append("<input type=\"submit\" value=\"Search\" title=\"Search\" name=\"do\" accesskey=\"s\" class=\"submit\" />"); $("#subtypes .subtype").eq(3).hide(); $("#pubrange span").html("For example: 1999-2001 for items published from 1999 through 2001. You could also use \"-1987\" for everything published before 1988 or \"2008-\" for everything published after 2007."); $("#ccode-17").parent().html(" "); $("#ccode-18").parent().html(" "); $("#ccode-19").parent().html(" "); $("#ccode-20").parent().html(" "); $("#ccode-21").parent().html(" "); }); //]]> So if you go to system preferences, then to the opac tab. The edit the opacuserjs ... take the js out, save it in a file somewhere so you can put it back. Then save, then try it. I did turn javascript off in firefox and it did fix it so I think this js is not doing quite what its designed to do. At least not in firefox. Hope this is some help. If removing the js fixes it you will probably need to get your support company to do you some fixed version. Or someone smarter at js than me anyway (Ive been doing web development since 1996, but have resisted learning js and more than rudimentary html .. people can't ask you do it if you don't know :-)) Chris -- Chris Cormack Catalyst IT Ltd. +64 4 803 2238 PO Box 11-053, Manners St, Wellington 6142, New Zealand
This may have something to do with the way our user interface is configured. I don't think it is happening in other LLEK catalogs.
The checkboxes always jump 6 spaces. Since we have the last five codes set to be invisible to users, the "jumping" only occurs with the first 11 choices.
You're right that it's your OPAC customization is to blame here, but I think the behavior you're observing is actually a bug in Firefox. In order to hide those ccode limiters this was added to your opacuserjs: $("#ccode-17").parent().html(" "); $("#ccode-18").parent().html(" "); $("#ccode-19").parent().html(" "); $("#ccode-20").parent().html(" "); $("#ccode-21").parent().html(" "); ...which removes the contents of those last 5 table cells. Since Chrome doesn't seem to have a problem with this, I'm guessing Firefox is losing track of which checkbox is which when determining where to place the check mark on a page loaded from the cache. Perhaps a workaround would be to hide those elements rather than remove them. Remove those lines from opacuserjs and replace them with this: $("#ccode-17").parent().hide(); $("#ccode-18").parent().hide(); $("#ccode-19").parent().hide(); $("#ccode-20").parent().hide(); $("#ccode-21").parent().hide(); -- Owen -- Web Developer Athens County Public Libraries http://www.myacpl.org
participants (3)
-
Chris Cormack -
Owen Leonard -
Stacy Pober