Updated Subject line. Sorry. I meant to add, that OOo grabs the file name via an xsl:param, which is passed through via a Cocoon pipeline. Will we want to do a similar thing with this odt plugin? Clay On Apr 24, 2006, at 9:12 PM, Web Maestro Clay wrote: > ODT uses a similar structure to OOo. I want to grab the document > title element (stored in 'odt_file.odt/meta.xml' as / > office:document-meta/office:meta/dc:title). But the ODT transformer > currently only looks at /content.xml. > > Here's what I've got so far: > > > > Insert Client Name > > method="xml" > indent="yes" > omit-xml-declaration="yes" > doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" > doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1- > transitional.dtd" > encoding="UTF-8" > /> > > <..> > > > > > > > > > <xsl:choose> > <!-- if no title element or h1 elements, display $filename --> > <xsl:when test="(/office:document-meta/office:meta/dc:title = > '' or > not(office:document-meta/office:meta/dc:title)) and > office:document-content/office:body/text:h[1] = ''"> > <xsl:value-of select="$filename"/> > </xsl:when> > <!-- if no title element, display 1st h1 --> > <xsl:when test="not(/office:document-meta/office:meta/dc:title) > and > office:document-content/office:body/text:h[1] != ''"> > <xsl:value-of select="office:document-content/office:body/ > text:h[1]"/> > </xsl:when> > <!-- display title element from ODT File:Properties --> > <xsl:otherwise> > <xsl:value-of select="/office:document-meta/office:meta/ > dc:title"/> > </xsl:otherwise> > </xsl:choose> > > > > > > > > > Clay Leeds webmaestro@mac.com My religion is simple. My religion is kindness. -- HH Dalai Lama of Tibet