Class: XmlController

Inherits:
BaseController show all
Defined in:
app/controllers/xml_controller.rb

Instance Method Summary collapse

Methods included from BlogHelper

#blog_base_url, #this_blog

Instance Method Details

#sitemapObject



4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# File 'app/controllers/xml_controller.rb', line 4

def sitemap
  @items = []
  @blog = this_blog

  @feed_title = this_blog.blog_name
  @link = this_blog.base_url
  @self_url = request.url

  @items += Article.find_already_published(1000)
  @items += Page.find_already_published(1000)
  @items += Tag.find_all_with_content_counters unless this_blog.unindex_tags

  respond_to do |format|
    format.googlesitemap
  end
end