내가 만든 RSS 피드로 작업하려고합니다. 그것은 2 개의 링크 된 CSS와 xls 문서를 가지고 있습니다. 하나의 CSS는 xsl이 작동하지 않는 경우를 대비 한 fail safe로, xls는 피드를 포맷 할 때 또 다른 CSS로 사용됩니다. URL입니다 여기에 있습니다 :Chrome에 RSS가 표시되지 않습니다.
XSL은 다음과 같습니다<?xml version="1.0" encoding="iso-8859-1"?>
<?xml-stylesheet type="text/css" href="http://www.rockthepatch.com/css/rss.css"?>
<?xml-stylesheet type="text/xsl" href="http://www.rockthepatch.com/rss/current-events.xsl"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<language>en-us</language>
<title>Upcoming Rock the Patch! Events</title>
<link>http://www.rockthepatch.com/rss/current-events.xml</link>
<description>See what's coming up below:</description>
<atom:link href="http://www.rockThePatch.com/rss/current-events.xml" rel="self" type="application/rss+xml" />
<item>
<title>Thursday's Open Mic at Ole Simms</title>
<link>https://www.facebook.com/olesimrells</link>
<description>Join Patches at open mic night at Terre Haute's Ole Simmerls Bar around 9 P.M. every Thursday.</description>
<guid>http://www.indstate.edu/mpa/sarah/rockThePatch/rss/item0001</guid>
<pubDate>Mon, 10 Oct 2011 09:15:00 EST</pubDate>
<author>[email protected] (Patches)</author>
</item>
<item>
<title>Fall Break is Here!</title>
<link>http://www.indstate.edu/academicaffairs/calendar.htm</link>
<description>School and work will not happen on Friday due to FALL BREAK!!! </description>
<guid>http://www.indstate.edu/mpa/sarah/rockThePatch/rss/item0002</guid>
<pubDate>Fri, 07 Oct 2011 02:23:00 EST</pubDate>
<author>[email protected] (Patches)</author>
</item>
</channel>
</rss>
가 :
<?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>
<head>
<link rel="stylesheet" href="http://www.rockthepatch.com/css/xsl.css" type="text/css"/>
</head>
<body>
<h2>Upcoming Rock the Patch! Events</h2>
<table border="1px">
<tr>
<th>Name of Event</th>
<th>Description</th>
<th>Date Posted</th>
<th>Author</th>
</tr>
<xsl:for-each select="rss/channel/item">
<tr>
<td>
<xsl:value-of select="title"/>
</td>
<!-- <td>
<a href="<xsl:value-of select='link'/>" title="Link">
<xsl:value-of select="link"/>
</a>
</td> -->
<td>
<xsl:value-of select="description"/>
</td>
<td>
<xsl:value-of select="pubDate"/>
</td>
<td>
<a href="mailto:[email protected]" title="[email protected]">
<xsl:value-of select="author"/>
</a>
</td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
난에 파일을 원하지 않는
http://rockthepatch.com/rss/current-events.xml
RSS 피드는 다음과 같습니다 다운로드 할 수 있지만 링크를 클릭 할 때마다 브라우저에서 표시하는 것과 반대되는 다운로드 ... 누군가 내가 잘못하고있는 것을 지적 할 수 있습니까?
실제로 나는 더 많은 연구를 호스팅하는 godaddy와 관련된 문제 일지 모르지만 여전히 확신 할 수 없다고 생각합니다. 나는 rss 헤더에 type = "application/rss + xml"을 추가했지만 여전히 운이 없다. – isuPatches
나는 이것도 얻고있다 : 리소스는 Document로 해석되지만 MIME 형식 application/rss + xml : "http://rockthepatch.com/rss/current-events.xml"로 전송된다. – isuPatches
나는 당신의 서버 응답을 가로 채는 바이올린을 가지고 놀았습니다. 아무것도 도움이되지 않는 것 같습니다. Chrome에는 RSS 피드 소비가 얼마나 빈약한지 보여주는 웹 자료가 많이 있습니다. 피드를 구독 할 수있는 기본 제공 방법이 없습니다. Google의 권장 사항은 RSS 구독 확장 프로그램을 설치하는 것입니다. https://chrome.google.com/webstore/detail/nlbjncdgjeocebhnmkbbbdekmmmcbfjd –