mirror of
https://github.com/discourse/discourse.git
synced 2024-12-13 09:43:44 +08:00
24 lines
1018 B
Plaintext
24 lines
1018 B
Plaintext
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
|
|
<channel>
|
|
<title><%= @title %></title>
|
|
<link><%= @link %></link>
|
|
<description><%= @description %></description>
|
|
<atom:link href="<%= @atom_link %>" rel="self" type="application/rss+xml" />
|
|
<% @topic_list.topics.each do |topic| %>
|
|
<item>
|
|
<title><%= topic.title %></title>
|
|
<description><![CDATA[
|
|
<p><%= pluralize(topic.posts_count, 'post') %></p>
|
|
<p><%= t 'author_wrote', author: topic.posts.first.author_readable %></p>
|
|
<%= topic.posts.first.cooked.html_safe %>
|
|
]]></description>
|
|
<link><%= Discourse.base_url %><%= topic.relative_url %></link>
|
|
<pubDate><%= topic.created_at.rfc2822 %></pubDate>
|
|
<guid><%= Discourse.base_url %><%= topic.relative_url %></guid>
|
|
<source url="<%= Discourse.base_url %><%= topic.relative_url %>.rss"><%= topic.title %></source>
|
|
</item>
|
|
<% end %>
|
|
</channel>
|
|
</rss>
|