for-each tag don't return any value

webmasterbeta

New Member
I'm still learning about xml and xsl.When I tried to return a html page with Xsl and Xmlthe data between tags <xsl:for-each select=""></xsl:for-each>don't return to the browser.Example:/***** Xsl File ****/<?xml version="1.0"?><xsl:stylesheet xmlns:xsl="http://www.w3.org/tr/wd-xsl"><xsl:template match="/"><html><table border="2" bordercolor="Red"><tr><td>Name</td><td>Address</td><td>Tel</td><td>Fax</td><td>Email</td></tr><xsl:for-each select="people/person"><tr><td><xsl:value-of select="name" /></td><td><xsl:value-of select="address" /></td><td><xsl:value-of select="tel" /></td><td><xsl:value-of select="fax" /></td><td><xsl:value-of select="email" /></td></tr></xsl:for-each></table></html></xsl:template></xsl:stylesheet>/************ Xml File ***********/<?xml version="1.0"?><?xml-stylesheet type="text/xsl" href=http://forums.devx.com/archive/index.php/"People.xsl"?><people><person><name>MarkWilson</name><address>911SomewhereCircle,Canberra,Australia</address><tel>61212345</tel><fax>61212345</fax><email>[email protected]</email></person></people>I can see only the following:--------------------------name address tel fax emailI can't see the childnodes, why?Thanks,Adriano.
 
Back
Top