problem extracting year from date
Richard Lyons
richard at lyons.art.br
Mon Oct 7 20:33:01 BST 2024
Hi.
I have three date fields in the tellico database I have created. Two are
cdate and mdate, and do not concern me here. The other is the date of
creation of the artwork in the collection. Tellico formats dates as
<date>
<year> </year>
<month> </month>
<day> </day>
</date>
For various reports, I want to insert just the year.
Other fields are exctacted easily with , for example
<xsl:value-of select="$entry/tc:altura"/>
but <xsl:value-of select="$entry/tc:data"/> outputs
a space-separated array, eg '2023 09 16'
How should I get just '2013' ? I have failed to discover a way of
outputting just the grand-child <year>. Shall I need to take a substring
(0,3) of the array? I do not know how to do that either :-(
Any guidance would be appreciated.
richard
--
Richard Lyons
More information about the tellico-users
mailing list