select child element of xPath with axes
Posted: Sat Dec 26, 2009 7:34 pm
Hi,
I want the title of my html file to be the value of a grandchild element from a xPath with axes.
That doesn't sounds as a clear explanation, but I'll try to clear it out.
This is a shortened version of my xml file:
I want "EskoArtwork XMP example file" to be the title of my html file.
I've tried the following code, but it doesn't work.
I want the title of my html file to be the value of a grandchild element from a xPath with axes.
That doesn't sounds as a clear explanation, but I'll try to clear it out.
This is a shortened version of my xml file:
Code: Select all
<?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?>
<?xml-stylesheet type="text/xsl" href="XMP_omvormen.xslt"?>
<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 4.2.2-c063 53.352624, 2008/07/30-18:05:41 ">
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about=""
xmlns:xmp="http://ns.adobe.com/xap/1.0/">
<xmp:CreateDate>2007-07-04T16:36:14+02:00</xmp:CreateDate>
<xmp:CreatorTool>Esko PackEdge 7.0 NT Jun 26 2007, build 627</xmp:CreatorTool>
<xmp:MetadataDate>2007-07-04T16:36:16+02:00</xmp:MetadataDate>
<xmp:ModifyDate>2007-07-04T16:36:16+02:00</xmp:ModifyDate>
<xmp:Rating>4</xmp:Rating>
</rdf:Description>
<rdf:Description rdf:about=""
xmlns:dc="http://purl.org/dc/elements/1.1/">
<dc:format>application/pdf</dc:format>
<dc:description>
<rdf:Alt>
<rdf:li xml:lang="x-default">esko pdf example file </rdf:li>
</rdf:Alt>
</dc:description>
<dc:title>
<rdf:Alt>
<rdf:li xml:lang="x-default">EskoArtwork XMP example file</rdf:li>
</rdf:Alt>
</dc:title>
<dc:creator>
<rdf:Seq>
<rdf:li>EskoArtwork</rdf:li>
</rdf:Seq>
</dc:creator>
<dc:subject>
<rdf:Bag>
<rdf:li>Esko</rdf:li>
<rdf:li>Artwork</rdf:li>
</rdf:Bag>
</dc:subject>
</rdf:Description>
</x:xmpmeta>
<?xpacket end="w"?>
I've tried the following code, but it doesn't work.
Code: Select all
<title>
<xsl:value-of select="rdf:Description[
namespace::*[.='http://purl.org/dc/elements/1.1/']
]/dc:title/rdf:Alt/rdf:li"/>
</title>