summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
Diffstat (limited to 'app/views')
-rw-r--r--app/views/rss/tag_updates.xml.builder27
-rw-r--r--app/views/tags/show.html.erb6
2 files changed, 33 insertions, 0 deletions
diff --git a/app/views/rss/tag_updates.xml.builder b/app/views/rss/tag_updates.xml.builder
new file mode 100644
index 0000000..6491cfc
--- /dev/null
+++ b/app/views/rss/tag_updates.xml.builder
@@ -0,0 +1,27 @@
1xml.instruct!
2
3xml.feed(:xmlns => "http://www.w3.org/2005/Atom", "xml:base" => @host) do
4 xml.title("Chaos Computer Club: #{@tag}")
5 xml.link(:href => "#{@host}/")
6 xml.link(:rel => "self", :href => "#{@host}/rss/tags/#{@tag}/updates.xml")
7 xml.updated(@items.first.published_at.xmlschema) unless @items.empty?
8 xml.author do
9 xml.name("Chaos Computer Club e. V.")
10 end
11 xml.id("#{@host}/rss/tags/#{@tag}/updates")
12
13 @items.each do |item|
14 xml.entry do
15 xml.title(CGI.escapeHTML(item.title.to_s))
16 xml.link(
17 :href => content_url(:page_path => item.node.unique_path),
18 :rel => "alternate",
19 :type => "text/html"
20 )
21 xml.id(content_url(:page_path => item.node.feed_id))
22 xml.updated(item.updated_at.xmlschema)
23 xml.published(item.published_at.xmlschema)
24 xml.summary(CGI.escapeHTML(item.abstract.to_s))
25 end
26 end
27end
diff --git a/app/views/tags/show.html.erb b/app/views/tags/show.html.erb
index b09cc15..3a23522 100644
--- a/app/views/tags/show.html.erb
+++ b/app/views/tags/show.html.erb
@@ -1,5 +1,11 @@
1<h2><%= t(:show_tag_headline) %> »<%=h @tag %>«</h2> 1<h2><%= t(:show_tag_headline) %> »<%=h @tag %>«</h2>
2 2
3<p class="feed_link">
4 <%= link_to "Subscribe to updates tagged »#{@tag}«",
5 rss_tag_url(:tag => @tag, :format => :xml),
6 :type => "application/atom+xml" %>
7</p>
8
3<%= 9<%=
4 render( 10 render(
5 :partial => 'custom/partials/no_date_and_author', 11 :partial => 'custom/partials/no_date_and_author',