adds an RSS feed for pages/all

This commit is contained in:
Manuel Wiedenmann 2014-01-04 20:12:01 +01:00
parent b4dfa50409
commit 0d0ff90a64
16 changed files with 170 additions and 6 deletions

View file

@ -1,6 +1,14 @@
# encoding: utf-8
class PagesController < ApplicationController
skip_before_filter :authenticate, :only => :all
before_filter :only => :all do
authenticate_or_token(['wiki', 'all'])
end
before_filter do
content_for :head, view_context.rss_meta_tag
end
def index
@page = Page.find_by_permalink "Home"
@ -114,6 +122,10 @@ class PagesController < ApplicationController
end
@pages.order(order)
end
respond_to do |format|
format.html
format.rss { render :layout => false }
end
end
def version