【发布时间】:2018-03-03 11:40:23
【问题描述】:
我把我的代码放在 XML 验证网站上,它给了我这个错误:
第 8 行:4 文档中根元素之后的标记必须格式正确。
有问题的行是<xsl:output method = "html" doctype-system = "about:legacy-compat"/>,行。
XML
<?xml version="1.0"?>
<!-- Fig. 15.21: sorting.xsl -->
<xsl:stylesheet version = "1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"/>
<!-- write XML declaration and DOCTYPE DTD information -->
*<xsl:output method = "html" doctype-system = "about:legacy-compat" />*
<!-- match document root -->
<xsl:template match="/"> -<html> <xsl:apply-templates/> </html>
</xsl:template>
【问题讨论】:
标签: xml xslt xml-parsing xml-validation