【发布时间】:2015-07-11 21:55:39
【问题描述】:
以下是 XML 和 XSLT 文件的源代码,我得到的输出是“Bold Text Italics Text”,粗体和斜体格式标记被忽略。如何调整此代码以确保应用所有标签并且我的输出文本为粗体/斜体?
XML 文件 (text.xml)
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="test.xsl"?>
<examples>
<example><b>Bold Text</b> <i>Italics Text</i></example>
</examples>
XSL 文件 (test.xsl)
<xsl:template match="/">
<html>
<head>
<title>Title</title>
</head>
<body>
<xsl:value-of select="examples/example"/>
</body>
</html>
</xsl:template>
【问题讨论】:
标签: html xml xslt tags formatting