Summary: | URL escape in OPAC more searches | ||
---|---|---|---|
Product: | Koha | Reporter: | Fridolin Somers <fridolin.somers> |
Component: | OPAC | Assignee: | Fridolin Somers <fridolin.somers> |
Status: | CLOSED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | P5 - low | CC: | chris, mtj |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
See Also: | https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37573 | ||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Circulation function: | |||
Attachments: |
Proposed patch
Bug 9504: URL escape in OPAC more searches Bug 9504: URL escape in OPAC more searches |
Description
Fridolin Somers
2013-01-29 17:02:41 UTC
Created attachment 14921 [details] [review] Proposed patch See commit message Created attachment 15019 [details] [review] Bug 9504: URL escape in OPAC more searches OPACSearchForTitleIn is a syspref used to add links as "more searches" in OPAC record detail page. The links can contain vars depending on record values like title, ISBN, ... Thoses values must be URL-escaped because they can contain special characters that will brake URL and/or HTML. This patch add a method C4::Output::parametrized_url() that replaces vars in URL usign escape and UTF-8 encoding. Test plan : - Define in OPACSearchForTitleIn a link with all possible vars : TITLE, AUTHOR, ISBN, ISSN, CONTROLNUMBER, BIBLIONUMBER - Edit a record to add special characters in title : ", &, ? ... - Go to OPAC detail pages of this record => Check that URL is well encoded => Click on link to check the term is well encoded (diacritical characters, ...) Signed-off-by: Liz Rea <liz@catalyst.net.nz> Nice test plan, thanks! Verified bug and fix - both look good. Created attachment 16446 [details] [review] Bug 9504: URL escape in OPAC more searches OPACSearchForTitleIn is a syspref used to add links as "more searches" in OPAC record detail page. The links can contain vars depending on record values like title, ISBN, ... Thoses values must be URL-escaped because they can contain special characters that will brake URL and/or HTML. This patch add a method C4::Output::parametrized_url() that replaces vars in URL usign escape and UTF-8 encoding. Test plan : - Define in OPACSearchForTitleIn a link with all possible vars : TITLE, AUTHOR, ISBN, ISSN, CONTROLNUMBER, BIBLIONUMBER - Edit a record to add special characters in title : ", &, ? ... - Go to OPAC detail pages of this record => Check that URL is well encoded => Click on link to check the term is well encoded (diacritical characters, ...) Signed-off-by: Liz Rea <liz@catalyst.net.nz> Nice test plan, thanks! Verified bug and fix - both look good. Signed-off-by: Mason James <mtj@kohaaloha.com> > Signed-off-by: Mason James <mtj@kohaaloha.com>
passing QA, patch tested and works well
testing 1 commit(s) (applied to 2f3cf47 'Merge branch 'bug_8979' into 3.12-mas')
This patch has been pushed to master. Pushed to 3.10.x will be in 3.10.5 |