requete XPath

"Boby" <[email protected]> Fri, 26 Jan 2007 12:24:33 +0100
Newsgroups gmane.text.xml.french.tech
Message-ID <[email protected]>
Bonjour à tous,

j'ai un probleme et je ne suis pas un cador du xml (meme si j'en manipule assez
frequemment)

J'ai decouvers recement les requetes XPath  :) et j'ai un probleme particulier
pour les documents XML utilisant un namespace specifique

Voici le document sur lequel je travaille

<?xml version="1.0" encoding="UTF-8"?>
<epp xmlns="urn:ietf:params:xml:ns:epp-1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-
 instance" xsi:schemaLocation="urn:ietf:params:xml:ns:epp-1.0 epp-1.0.xsd">
  <command>
    <create>
      <domain:create xmlns:domain="urn:ietf:params:xml:ns:domain-1.0"
xsi:schemaLocation="urn:
       ietf:params:xml:ns:domain-1.0 domain-1.0.xsd">
        <domain:name>domainetest.at</domain:name>
        <domain:period unit="y">10</domain:period>
        <domain:ns>
          <domain:hostAttr>
            <domain:hostName>ns1.domaine.fr</domain:hostName>
          </domain:hostAttr>
          <domain:hostAttr>
            <domain:hostName>ns2.domaine.fr</domain:hostName>
          </domain:hostAttr>
        </domain:ns>
        <domain:registrant>BB2577284</domain:registrant>
        <domain:contact type="admin">BB2577284</domain:contact>
        <domain:contact type="tech">FC2577283</domain:contact>
        <domain:authInfo>
          <domain:pw>jwsjem17z</domain:pw>
        </domain:authInfo>
      </domain:create>
    </create>
    <clTRID>DOMAINE_FR_1169742135921</clTRID>
  </command>
</epp>



Mon but ici est d'arriver à l'element <domain:pw>, je parviens à parcourir
l'arborescence en utilisant child::*/ (de maniere recursive) mais jamais en lui
indiquant le nom de l'element directement

//* me renvoi l'arborescence complete [[Element: <epp [Namespace:
urn:ietf:params:xml:ns:epp-1.0]/>], [Element: <command [Namespace:
urn:ietf:params:xml:ns:epp-1.0]/>], [Element: <create ...

mai une requete de type
//epp/*
ou
/epp/* me renvoi null systematiquement

Quelqu'un aurait une piste?

Cordialement,
Boby