Hi Lars, Ok, I've been letting this percolate. It looks like the problem may be that the outside for-each is taking you into a different branch of the mets tree than the dim is in: mets:fileGrp for the jpeg info, as opposed to mets:dmdSec for the dim:field info.
So I think you'll need to specify the path to the dim data from the top of the tree. I'm not sure about the exact form, but something like test="./mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']/mets:xmlData/dim:dim/dim:field[@element='contributor'][@qualifier='other']" might be close, for the xsl:when statement. B-- -----Original Message----- From: Lars Moeller [mailto:[email protected]] Sent: Wednesday, February 13, 2013 12:14 PM To: Brian Freels-Stendel Cc: [email protected] Subject: Re: [Dspace-tech] problem addressing fields Hi Brian, This isn't a problem of qualifier or no qualifier! The field dc.contributor.other is correct. But it is an example. It also doesn't work with dc.title in this for-each. The problem exists in combination with the for-each statement. I believe within this for-each the path dim:bla bla is wrong! But I don't know how to address this absolute. Best Lars Am 13.02.2013 um 18:33 schrieb Brian Freels-Stendel <[email protected]>: > Hi Lars, > > For an unqualified contributor, the path would be > dim:field[@element='title'][not(@qualifier)] > > To test for qualifiers different from 'other', just switch out the value of > the qualifier. So if you were looking for contributor.author: > dim:field[@element='contributor'][@qualifier='author'] > > If you want to find everything except contributor.other, then I think it > would be: dim:field[@element='title'][not(@qualifier='other')] > > B-- > > -----Original Message----- > From: Lars Möller [mailto:[email protected]] > Sent: Wednesday, February 13, 2013 10:16 AM > To: [email protected] > Subject: [Dspace-tech] problem addressing fields > > > hello, > > i have problems addressing fields running a for-each statement. > the images in the for-each statements are printed out fine. > the contributor does not match the test statement. > > can someone show me the path (absolute or relative) in this case for fetching > the contributor? > > best > lars > > > <xsl:template match="dim:dim" mode="itemSummaryView-DIM"> > <xsl:for-each > select="//mets:fileGrp[@USE='CONTENT']/mets:file[@MIMETYPE='image/jpeg']"> > ***** fetch images works fine > <xsl:choose> > **** does not work **** > <xsl:when test="dim:field[@element='contributor'][@qualifier='other']"> > <div class="contributor-other"><span > class="label"><i18n:text>xmlui.dri2xhtml.METS-1.0.contributor-other</i18n:text></span> > <xsl:text> </xsl:text> > <xsl:for-each > select="dim:field[@element='contributor'][@qualifier='other']"> > <xsl:copy-of select="node()"/> > <xsl:if > test="count(following-sibling::dim:field[@element='contributor'][@qualifier='other']) > != 0"> > <xsl:text>; </xsl:text> > </xsl:if> > </xsl:for-each> > </div> > </xsl:when> > </xsl:choose> > </xsl:for-each> > </xsl:template> > > ------------------------------------------------------------------------------ > Free Next-Gen Firewall Hardware Offer > Buy your Sophos next-gen firewall before the end March 2013 and get the > hardware for free! Learn more. > http://p.sf.net/sfu/sophos-d2d-feb > _______________________________________________ > DSpace-tech mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/dspace-tech > List Etiquette: > https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette > > ------------------------------------------------------------------------------ Free Next-Gen Firewall Hardware Offer Buy your Sophos next-gen firewall before the end March 2013 and get the hardware for free! Learn more. http://p.sf.net/sfu/sophos-d2d-feb _______________________________________________ DSpace-tech mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/dspace-tech List Etiquette: https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette

