Create sitemaps_controller.rb
This commit is contained in:
16
app/controllers/sitemaps_controller.rb
Normal file
16
app/controllers/sitemaps_controller.rb
Normal file
@@ -0,0 +1,16 @@
|
||||
class SitemapsController < ApplicationController
|
||||
|
||||
layout :false
|
||||
before_action :init_sitemap
|
||||
|
||||
def index
|
||||
@forums = Forum.all
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def init_sitemap
|
||||
headers['Content-Type'] = 'application/xml'
|
||||
end
|
||||
|
||||
end
|
||||
Reference in New Issue
Block a user