Class: KitsuneController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/kitsune_controller.rb

Instance Method Summary collapse

Instance Method Details

#showObject

Raises:

  • (::ActionController::RoutingError)


2
3
4
5
6
7
# File 'app/controllers/kitsune_controller.rb', line 2

def show 
  @page = ::Page.find_by_url('/'+[params[:url]].flatten.join('/'))
  raise ::ActionController::RoutingError, "No route matches #{request.path.inspect}" unless @page.present?
@title = @page.title
render :layout => @page.layout if @page.layout
end