XML中的Id属性和parentId属性如何用Xslt来控制输出

shgh800 2008-04-01 03:28:16
<Node Id="7" ParentId="2">
<NodeData>
<Cell xsi:type="xsd:string">dealerq1@fx</Cell>
<Cell xsi:type="xsd:string">dealer</Cell>
<Cell xsi:nil="true" />
<Cell xsi:nil="true" />
<Cell xsi:nil="true" />
<Cell xsi:nil="true" />
</NodeData>
</Node>
<Node Id="8" ParentId="7">
<NodeData>
<Cell xsi:type="xsd:string" />
<Cell xsi:nil="true" />
<Cell xsi:type="xsd:string">FX-DESK-SELF</Cell>
<Cell xsi:type="xsd:string">balance</Cell>
<Cell xsi:nil="true" />
<Cell xsi:type="xsd:string">USD</Cell>
</NodeData>
</Node>


XML中<Node Id="7" ParentId="2">的Id属性和parentId属性如何用Xslt来控制输出;
我要便利所有Node节点,并对Id属性的值做判断。。。。
...全文
93 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
UltraBejing 2008-05-01
  • 打赏
  • 举报
回复
关注 接分
meiZiNick 2008-05-01
  • 打赏
  • 举报
回复
不知,帮顶
smartcatiboy 2008-04-01
  • 打赏
  • 举报
回复
<xsl:template match="//Node">
属性Id=<xsl:value-of select="@Id"/>
<xsl:if test="@ParentId > 2">ParentID大于2</xsl:if>
</xsl:template>

8,907

社区成员

发帖
与我相关
我的任务
社区描述
XML/XSL相关问题讨论专区
社区管理员
  • XML/XSL社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧