xslt,想显示两列数据
时间:2011-07-12
来源:互联网
xslt,想显示两列数据。
xml:
<?xml version="1.0" standalone="yes" ?>
- <NewDataSet>
- <Table>
<XML_F52E2B61-18A1-11d1-B105-00805F49916B>
<b PreferredName="吴妙" Birthday="07-20"/>
<b PreferredName="蒋大宏" Birthday="07-22"/>
<b PreferredName="林妙可" Birthday="07-01"/>
<b PreferredName="程昱" Birthday="07-14"/>
<b PreferredName="王志" Birthday="07-03"/>
<b PreferredName="吴国桢" Birthday="07-31"/>
<b PreferredName="李文" Birthday="07-25"/>
<b PreferredName="株距" Birthday="07-20"/>
<b PreferredName="张路" Birthday="07-07"/>
</XML_F52E2B61-18A1-11d1-B105-00805F49916B>
</Table>
</NewDataSet>
xslt:
<?xml version="1.0" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:output method="html" version="1.0" encoding="UTF-8" indent="yes"/>
<xsl:template match="/">
<html>
<body>
<table border="0">
<xsl:for-each select="NewDataSet/Table">
<tr>
<td>
<xsl:value-of select="PreferredName"/>
<xsl:value-of select="Birthday"/>
</td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
现在显示的是
吴妙 07-20
蒋大宏 07-22
林妙可 07-01
程昱 07-14
…… ……
…… ……
我想要的是
吴妙 07-20 蒋大宏 07-22
林妙可 07-01 程昱 07-14
…… ……
…… ……
就是开始显示的是一列,我想有两列显示。我接触xslt时间不长。就大侠帮忙。谢谢
xml:
<?xml version="1.0" standalone="yes" ?>
- <NewDataSet>
- <Table>
<XML_F52E2B61-18A1-11d1-B105-00805F49916B>
<b PreferredName="吴妙" Birthday="07-20"/>
<b PreferredName="蒋大宏" Birthday="07-22"/>
<b PreferredName="林妙可" Birthday="07-01"/>
<b PreferredName="程昱" Birthday="07-14"/>
<b PreferredName="王志" Birthday="07-03"/>
<b PreferredName="吴国桢" Birthday="07-31"/>
<b PreferredName="李文" Birthday="07-25"/>
<b PreferredName="株距" Birthday="07-20"/>
<b PreferredName="张路" Birthday="07-07"/>
</XML_F52E2B61-18A1-11d1-B105-00805F49916B>
</Table>
</NewDataSet>
xslt:
<?xml version="1.0" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:output method="html" version="1.0" encoding="UTF-8" indent="yes"/>
<xsl:template match="/">
<html>
<body>
<table border="0">
<xsl:for-each select="NewDataSet/Table">
<tr>
<td>
<xsl:value-of select="PreferredName"/>
<xsl:value-of select="Birthday"/>
</td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
现在显示的是
吴妙 07-20
蒋大宏 07-22
林妙可 07-01
程昱 07-14
…… ……
…… ……
我想要的是
吴妙 07-20 蒋大宏 07-22
林妙可 07-01 程昱 07-14
…… ……
…… ……
就是开始显示的是一列,我想有两列显示。我接触xslt时间不长。就大侠帮忙。谢谢
作者: ququhahaking 发布时间: 2011-07-12
自己先顶顶
作者: ququhahaking 发布时间: 2011-07-12
没人能帮我吗?自己再顶顶
作者: ququhahaking 发布时间: 2011-07-12
相关阅读 更多
热门阅读
-
office 2019专业增强版最新2021版激活秘钥/序列号/激活码推荐 附激活工具
阅读:74
-
如何安装mysql8.0
阅读:31
-
Word快速设置标题样式步骤详解
阅读:28
-
20+道必知必会的Vue面试题(附答案解析)
阅读:37
-
HTML如何制作表单
阅读:22
-
百词斩可以改天数吗?当然可以,4个步骤轻松修改天数!
阅读:31
-
ET文件格式和XLS格式文件之间如何转化?
阅读:24
-
react和vue的区别及优缺点是什么
阅读:121
-
支付宝人脸识别如何关闭?
阅读:21
-
腾讯微云怎么修改照片或视频备份路径?
阅读:28