Summary: | OPAC detail page broken with XSLT | ||
---|---|---|---|
Product: | Koha | Reporter: | Fridolin Somers <fridolin.somers> |
Component: | OPAC | Assignee: | Fridolin Somers <fridolin.somers> |
Status: | CLOSED FIXED | QA Contact: | |
Severity: | major | ||
Priority: | P5 - low | CC: | chris, mtj, paul.poulain |
Version: | 3.8 | ||
Hardware: | All | ||
OS: | All | ||
See Also: |
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6314 http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8678 http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8615 |
||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Circulation function: | |||
Attachments: |
OPAC detail page broken
Proposed patch Proposed patch (all MARC) Bug 8513: OPAC detail page broken with XSLT |
Created attachment 11191 [details] [review] Proposed patch I found the problem : In some cases, the XSLT generates an empty a tag : <a href="..." /> This brakes the page. The concerned code is the building of subjects. Correction : ------------ Subject field with authority code ($9) : if the content of <a> is empty (= $display variable), it is set with the $9 value. Subject field without authority code ($9) : added a test on $a not empty, to avoid the same problem. Test plan : ----------- Bug appears on a record with a subject field (ie 606) containing a $9 as last subfield. Check also a record with a subject field containing some fields but not $9 nor $a. Fridolyn, does this only occur in UNIMARC, or does NORMARC and MARC21 have the same problem? Created attachment 11378 [details] [review] Proposed patch (all MARC) Added same control on 'm880Select' template used in MARC21 and NORMARC. Note that there are a lot of links in intranet XSLT, the problem can appear there. For me, the problem could be solved by changing XSTL output method. I send a mail 'XSLT output method' to koha-devel to open the discussion. Created attachment 11478 [details] [review] Bug 8513: OPAC detail page broken with XSLT Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> (In reply to comment #5) > Created attachment 11478 [details] [review] > Bug 8513: OPAC detail page broken with XSLT > > Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> patch looks good and applies, passing QA fyi: we need to add some xsl, xml and javascript tests to the Koha qa-tools... :) Check xt and xt/author tests for the xml and xslt already exist prove t/00-valid-xml.t t/00-valid-xml.t .. ok All tests successful. Files=1, Tests=94, 5 wallclock secs ( 0.10 usr 0.01 sys + 0.47 cusr 0.68 csys = 1.26 CPU) Result: PASS Pushed to 3.8.x, will be in 3.8.4 Patch pushed, but the same problem also exist in staff interface I think, I just checked intranet-tmpl/prog/en/xslt/MARC21slimUtils.xsl, and the same code is here. Paul is there a bug for the staff side? (In reply to comment #10) > Paul is there a bug for the staff side? This will be fixed by bug 8678. |
Created attachment 11158 [details] OPAC detail page broken When using OPACXSLTDetailsDisplay = default, the OPAC detail page includes the HTML code of a result page, see screen shot. Very odd.