On Fri, Dec 07, 2018 at 04:21:52PM +0000, Tami Wilkerson wrote:
Koha newbie here, so please pardon my ignorance! Is there a way to choose which 650 fields display in the OPAC? I would like ours to only show Library of Congress subjects (650 0_0) and suppress all others.
You can customize this by editing some XSLT. Check the system preference OPACXSLTDetailsDisplay; if it's set to "default" then your Koha is probably using this file to build the detailed record display: /usr/share/koha/intranet/htdocs/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl You can customize this to display a 650 field only if indicator 2 is 0. I haven't done this, so take this with a grain of salt, but I believe the way to proceed is to copy this file, edit the copy -- check it with _xsltproc_, or with _xmllint --noout_ if you just want to make sure it's at least well-formed XML -- and then change the system preference to use the edited copy and see if it's working the way you want. (Be prepared to change it back quickly!) The file we have (Koha 18.05) deals with subject fields in a block that begins like this: 683 <xsl:if test="marc:datafield[substring(@tag, 1, 1) = '6' and not(@tag=655)]"> 684 <span class="results_summary subjects"><span class="label">Subject(s): </span> 685 <xsl:for-each select="marc:datafield[substring(@tag, 1, 1) = '6'][not(@tag=655)]"> It shouldn't be hard to find in your version, even if the line numbers are different. Try changing the XPath criteria from this: marc:datafield[substring(@tag, 1, 1) = '6' and not(@tag=655)] To something like this: marc:datafield[substring(@tag, 1, 1) = '6' and not(@tag=655) and @ind2=0] But be careful, and check the LC docs for 6xx fields, since indicator 2 doesn't have the same meaning in all of them. I'm not a cataloger, so I'll leave that to you (or others) to figure out. :-) HTH, Paul. -- Paul Hoffman <paul@flo.org> Software Services Manager Fenway Library Organization 550 Huntington Ave. Boston, MA 02115 (617) 442-2384