に含まれているとき、私はXSLファイルスタイルシートが
<?xml version="1.0" encoding="UTF-8"?> <?xml-stylesheet href="rss2.xsl" type="text/xsl" media="screen"?> <rss version="2.0"> <channel>
<title>TITLE</title>
<description>Description</description>
<link>
some link
</link>
<copyright>Copyrights 2012, All Rights Reserved</copyright>
<item>
<title> title 1</title>
<description> desc</description>
<link>
some link
</link>
</item> </channel> </rss>
のようなコードを使用してXMLファイルを持っており、このためのXSLファイルは、私は、スタイルシートのコードにコメントをする際の問題がある
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html" />
<xsl:template match="/">
<html>
<head>
<title>XML RSS Feed</title>
<link type="text/css" rel="stylesheet" href="rss_xsl.css" >
</head>
<body>
<h2>XML RSS Feed</h2>
<hr />
<div id="content">
<xsl:for-each select="rss/channel/item">
<div class="article">
<h3><a href="{link}" rel="bookmark"><xsl:value-of select="title"/></a></h3>
<p><xsl:value-of select="description"/></p>
</div>
</xsl:for-each>
</div>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
ですクロムは飼料を示す。スタイルを含めると、フィードは表示されなくなります。どのようにしてフィードを表示するのを止めることができますか? XSLファイル用のStyleのこの組み込みで、いくつかのことが間違っています。
ニュース、スポーツ、アップデート、エンターテインメントのために私が持っているすべての異なるタイプのフィードに対してこのファイルを動作させたいという別の問題が1つあります。どのように動的にタイトルなどのようなXSLファイルの見出しを変更することができますか? – HardCode
本当に新しい質問をする必要がありますが、もちろん