가능한 중복 :
How can I make XSLT work in chrome?왜이 XML 파일에 아무것도 표시되지 않습니까?
내가이 XML 파일이 :
이 XSL 파일에 대한 링크<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="catalog.xsl"?>
<catalog>
<album>
<title>Exodus</title>
<artist>Bob Marley</artist>
<country>Jamaica</country>
<price>19,99</price>
</album>
<album>
<title>Black Album</title>
<artist>Metallica</artist>
<country>USA</country>
<price>20,00</price>
</album>
<album>
<title>Nevermind</title>
<artist>Nirvana</artist>
<country>USA</country>
<price>22,00</price>
</album>
</catalog>
:
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<html>
<body>
<h2>My Catalog</h2>
<table border="1">
<tr bgcolor="#9ACD32">
<th>Title</th>
<th>Artist</th>
</tr>
<xsl:for-each select="catalog/album">
<tr>
<td><xsl:value-of select="title"/></td>
<td><xsl:value-of select="artist"/></td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
W 암탉 나는 브라우저에서 XML 파일을 열어, 아무것도 표시되지 않습니다. 지시 된대로 자습서에서 복사 한 이후로, 나는 여기서 무엇이 잘못되었는지 확신하지 못합니다. 디스플레이 부족을 유발할 수있는 요소에 대한 단서가 있습니까?
관련이있다 :
난 당신이 파일을 사용하여 액세스 같은데요. 브라우저 문제? – keyser
@ Keyser : Chrome에서 사용해 보았습니다. 너는 무엇에서 이것을 시도 했는가? – stanigator
나를 위해 일했습니다. – Drona