File: app/models/file_not_found_page.rb

Overview
Module Structure
Class Hierarchy
Code

Overview

Module Structure

  module: <Toplevel Module>
  class: FileNotFoundPage#1
inherits from
  Page   
has properties
method: allowed_children #3
method: virtual? #20
method: response_code #24
method: cache? #28

Class Hierarchy

Object ( Builtin-Module )
Base ( ActiveRecord )
Page
  FileNotFoundPage    #1

Code

   1  class FileNotFoundPage < Page
   2    
   3    def allowed_children
   4      []
   5    end
   6    
   7    description %{
   8      A "File Not Found" page can be used to override the default error
   9      page in the event that a page is not found among a page's children.
  10      
  11      To create a "File Not Found" error page for an entire Web site, create
  12      a page that is a child of the root page and assign it "File Not Found"
  13      page type.
  14    }
  15    
  16    tag "attempted_url" do |tag|
  17      CGI.escapeHTML(request.request_uri) unless request.nil?
  18    end
  19     
  20    def virtual?
  21      true
  22    end
  23     
  24    def response_code
  25      404
  26    end
  27    
  28    def cache?
  29      false
  30    end
  31    
  32  end