[XML4Lib] xpath expression [resolved]

Eric Lease Morgan emorgan at nd.edu
Fri Sep 21 12:45:28 EDT 2007


On Sep 21, 2007, at 11:57 AM, David Sewell wrote:

> If you are using something that supports XPath 2.0, this will retrieve
> only elements named "c" or "c01" .. "c12":
>
>    //*[matches(local-name(.), '^c(0\d|1[0-2])*$')]
>
> With XPath 1.0 I think it's going to require
>
>   <xsl:for-each select='//c|//c01|//c02|//c03'>


Thank you for the prompt replies, and who needs a reference book when  
you have a mailing list like this. I'm going for the second XPath  
statement, above.

BTW, David will be presenting some of his good work at the TEI  
conference in November. I'm sure he will represent UVA Press very well:

   Digital Scholarship from Heterogeneous TEI Sources: Workflows and
   Tools at the University of Virginia Press's ROTUNDA Imprint

   David Sewell (University of Virginia Press)

   For four years, the University of Virginia Press has been
   preparing and publishing digital scholarly publications based in
   all cases on documentary data encoded in TEI-XML. But our seven
   completed publications differ widely in the origin and nature of
   their underlying data (born-digital versus digitized print, for
   example), their versions and/or dialects of TEI, and their user
   interfaces. We will discuss the workflows we have developed for
   working with both project authors and data conversion vendors;
   the tools we use for editing, transforming, and checking XML
   data; and our publication delivery system.

   http://www.lib.umd.edu/dcr/events/teiconference/


-- 
Eric Lease Morgan
University Libraries of Notre Dame

(574) 631-8604




More information about the XML4Lib mailing list