This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Namespace ?
- From: "stephane" <sbirot at e-manation dot com>
- To: <xsl-list at lists dot mulberrytech dot com>
- Date: Thu, 25 Jul 2002 14:28:21 +0200
- Subject: [xsl] Namespace ?
- Reply-to: xsl-list at lists dot mulberrytech dot com
I want to extract the FormattedName from the following XML file:
<?xml version="1.0" encoding="UTF-8"?>
<Resume xmlns="http://ns.hr-xml.org/RecruitingAndStaffing/SEP-2_0">
<StructuredXMLResume>
<ContactInfo>
<PersonName>
<FormattedName>John Doe</FormattedName>
</PersonName>
</ContactInfo>
</StructuredXMLResume>
</Resume>
I use the following XSL file:
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:template match="/">
<html>
<head>
<title>
<xsl:value-of
select="Resume/StructuredXMLResume/ContactInfo/PersonName/FormattedName"
/>
</title>
</head>
<body>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
But this does not work.
In the XML file if I replace
<Resume xmlns="http://ns.hr-xml.org/RecruitingAndStaffing/SEP-2_0">
By
<Resume>
This work fine
Could anybody explain me why ?
---
Stéphane
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list