Dear Brian, Thats a great solution! Thanks! Best Lizzy
-----Oorspronkelijk bericht----- Van: [email protected] [mailto:[email protected]] Namens Brian Wolff Verzonden: vrijdag 11 september 2015 12:14 Aan: Conversations revolving around the development of GLAM Digital Tools <[email protected]> Onderwerp: Re: [Glamtools] New at this and trying to configure our API On 9/11/15, Lizzy Jongma <[email protected]> wrote: > Dear all, > > > > My name is Lizzy Jongma. I am datamanager at the Rijksmuseum and I am > currently trying to do a (new) batch upload to Wikimedia Commons with > the Batch Upload tool. > > We are currently mapping our internal metadata to the GLAMwiki > format(s) and as you can all imagine: this always leads to a million > questions. I will not send you all a million questions but I would like to > send you all this one: > > > These are the dimensions of an object in our collection, written down > in Adlib and then exported as XML to our website: > > 1. <dimension> > > 2. <dimension.notes> > > 3. <value lang="0"/> > > 4. <value lang="1"/> > > 5. </dimension.notes> > > 6. <dimension.unit> > > 7. <value lang="0">cm</value> > > 8. <value lang="1">cm</value> > > 9. </dimension.unit> > > 10.<dimension.value> > > 11.<value lang="0">379.5</value> > > 12.<value lang="1">379,5</value> > > 13.</dimension.value> > > 14.<dimension.type> > > 15.<value lang="0">height</value> > > 16.<value lang="1">hoogte</value> > > 17.</dimension.type> > > 18.</dimension> > > 19.<dimension> > > 20.<dimension.notes> > > 21.<value lang="0"/> > > 22.<value lang="1"/> > > 23.</dimension.notes> > > 24.<dimension.unit> > > 25.<value lang="0">cm</value> > > 26.<value lang="1">cm</value> > > 27.</dimension.unit> > > 28.<dimension.value> > > 29.<value lang="0">w</value> > > 30.<value lang="1">453,5</value> > > 31.</dimension.value> > > 32.<dimension.type> > > 33.<value lang="0">width</value> > > 34.<value lang="1">breedte</value> > > 35.</dimension.type> > > 36.</dimension> > > 37.<dimension> > > 38.<dimension.notes> > > 39.<value lang="0"/> > > 40.<value lang="1">gewicht met lijst</value> > > 41.</dimension.notes> > > 42.<dimension.unit> > > 43.<value lang="0">kg</value> > > 44.<value lang="1">kg</value> > > 45.</dimension.unit> > > 46.<dimension.value> > > 47.<value lang="0">337</value> > > 48.<value lang="1">337</value> > > 49.</dimension.value> > > 50.<dimension.type> > > 51.<value lang="0">weight</value> > > 52.<value lang="1">gewicht</value> > > 53.</dimension.type> > > 54.</dimension> > > 55.<dimension> > > > (XSLT: And in our web CMS we put this XSLT: > <!-- dimensions --> > <xsl:element name="dcterms:SizeOrDuration"> > <xsl:text>{{Size|unit=</xsl:text> > <xsl:value-of > select="dimension/dimension.unit/value[@lang=0]"/> > <xsl:apply-templates select="dimension"/> > <xsl:text>}}</xsl:text> > </xsl:element> > > <xsl:template match="dimension"> > <xsl:text>|</xsl:text> > <xsl:value-of select="dimension.type/value[@lang=0]"/> > <xsl:text>=</xsl:text> > <xsl:value-of select="dimension.value/value[@lang=0]"/> > </xsl:template> > ) > > I am currently writing an XSLT stylesheet to transform this XML to the > Wikimedia format for documenting Works of Art: > > Dimensions - dcterms: SizeOrDuration ('class') - dimensions Use Size > formatting template: Dimensions of the artwork: 1D (length), 2D (width > × height) or 3D (width × height × depth). Please use > {{Size}}<https://commons.wikimedia.org/wiki/Template:Size> formatting > template, such as: > {{Size|unit=cm|width=76.7|height=83.5}} <- gives Height: 83.5 cm (32.9 in). > Width: 76.7 cm (30.2 in). > > But, as you can see Size only consists of one type of unit and our > dimensions consist of two types of units for specific parts. > > How do I solve this? Repeat dcterms: SizeOrDuration ('class') for > different units? Ignore units for weights etc? > > Thanks for your input! > > Best wishes > > Lizzy Jongma > > [cid:[email protected]] > > > > Museumstraat 1 > > Postbus 74888 > > 1070 DN Amsterdam > > > > Rijksmuseum.nl<http://www.rijksmuseum.nl/> > > > t/m 21 sept | Uit en thuis<https://www.rijksmuseum.nl/nl/uit-en-thuis> > Landschapstekeningen uit de John en Marine van Vlissingen Collectie > t/m 27 sept | New for Now<https://www.rijksmuseum.nl/nl/new-for-now> > The origin of fashion magazines t/m 15 november | Dick Bruna. > Kunstenaar<https://www.rijksmuseum.nl/nl/bruna> > Formatting it like {{size|cm|height=379.5}} {{size|cm|width=453.5}} {{weight|kg|337}} seems like the most logical course, if you're not sure all the units for height/width will be the same. -- -bawolff _______________________________________________ Glamtools mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/glamtools _______________________________________________ Glamtools mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/glamtools
