Jump to content

obiwankenobi

Members
  • Posts

    2
  • Joined

  • Last visited

obiwankenobi's Achievements

Newbie

Newbie (1/7)

0

Reputation

  1. It works now (blessed be templates!) but still the problem remains.What's wrong with namespaces? I saw that if I try to reach the nodes by the name() and node() functions, they work, but no absolute or relative paths are accepted.So, basically, the question is, how to deal with xmlns?thanks again dude, much appreciated
  2. hello everyonemore than a problem this is a question - for I've already fixed the problem in a "dirty" way, but I'd like to find out from which is generated.this is my xml<myroot xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.somethingcom/"><tag1>something</tag1><tag2><tag3>something'>http://www.somethingcom/"><tag1>something</tag1><tag2><tag3>something else</tag3><tag3>something else more</tag3></tag2></myroot>and here's the xsl<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:template match="/"><html><body><p>Tag One: <xsl:value-of select="//tag1"></p><xsl:for-each select="/myroot/tag2/*"><p>middle tags: <xsl:value-of select="tag3"/></p></xsl:for-each></body></html></xsl:template>when I try to transform it, if there's the namespace attribute (xmlns="http://www.somethingcom/") no matter what I do, no tag is read (even if I try to reach the tag by the absolute xpath "//tag1"). If I remove the attribute "xmlns", it works perfectly.Can anyone explain me what I'm supposed to do to have it be read even with that atttribute?Thanks bunchJedi MasterObi-Wan KenobiMay the Force be with you
×
×
  • Create New...