Bug 9087 - In Search.pl if there is parenthesis in itemcallnumber the link is broken
Summary: In Search.pl if there is parenthesis in itemcallnumber the link is broken
Status: CLOSED INVALID
Alias: None
Product: Koha
Classification: Unclassified
Component: Searching (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Target Milestone: ---
Assignee: Christophe Croullebois
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-15 10:26 UTC by Christophe Croullebois
Modified: 2014-12-07 20:03 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:


Attachments
proposed patch (2.06 KB, patch)
2012-11-15 11:11 UTC, Christophe Croullebois
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Christophe Croullebois 2012-11-15 10:26:44 UTC
The search with parenthesis in 'q=xxxxx(x)xx' raises an error message "Can't call method "sort" on an undefined value at /home/koha/src/C4/Search.pm line 404."
The easier way to solve this problem is to put quotes for the query, q="xxxx(x)xx"
Comment 1 Christophe Croullebois 2012-11-15 11:11:18 UTC
Created attachment 13458 [details] [review]
proposed patch

To test, do a search, in the search.pl, find a line with parenthesis in itemcallnumber eg: [EMP 133.620 (1) CCL.5294] and click on the link, without patch you'll have an error message.
With the patch, the link is ok, an you can see the request as:
cgi-bin/koha/catalogue/search.pl?idx=callnum&q="EMP 133.620 (1) CCL.5294"
Comment 2 Melia Meggs 2012-11-16 20:36:16 UTC
I wanted to test this, but I can't seem to reproduce that error message on master.

I did a search for an item that has call number [AR EUch (Thu) 1974], but I don't get any error message when I click on it in the staff client or the OPAC.
Comment 3 Kyle M Hall 2012-11-21 13:59:41 UTC
I too am unable to reproduce this on master.
Comment 4 Owen Leonard 2013-09-13 19:06:28 UTC
I'm marking this invalid since it's been a year and no one has been able to reproduce.