From b198e9fe949b7ef53bf9573ae58c181b9e5bf897 Mon Sep 17 00:00:00 2001 From: evanweaver Date: Mon, 29 Oct 2007 05:37:35 +0000 Subject: update comment git-svn-id: svn+ssh://rubyforge.org/var/svn/mongrel/trunk@826 19e92222-5c0b-0410-8929-a290d50e31e9 --- lib/mongrel/handlers.rb | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'lib/mongrel') diff --git a/lib/mongrel/handlers.rb b/lib/mongrel/handlers.rb index 499d69f..ee76179 100644 --- a/lib/mongrel/handlers.rb +++ b/lib/mongrel/handlers.rb @@ -69,9 +69,11 @@ module Mongrel end + # # The server normally returns a 404 response if an unknown URI is requested, but it # also returns a lame empty message. This lets you do a 404 response # with a custom message for special URIs. + # class Error404Handler < HttpHandler # Sets the message to return. This is constructed once for the handler @@ -87,24 +89,25 @@ module Mongrel end - + # # Serves the contents of a directory. You give it the path to the root # where the files are located, and it tries to find the files based on # the PATH_INFO inside the directory. If the requested path is a # directory then it returns a simple directory listing. # # It does a simple protection against going outside it's root path by - # converting all paths to an absolute expanded path, and then making sure - # that the final expanded path includes the root path. If it doesn't + # converting all paths to an absolute expanded path, and then making + # sure that the final expanded path includes the root path. If it doesn't # than it simply gives a 404. # # If you pass nil as the root path, it will not check any locations or - # expand any paths. This lets you serve files from multiple directories + # expand any paths. This lets you serve files from multiple drives # on win32. # # The default content type is "text/plain; charset=ISO-8859-1" but you # can change it anything you want using the DirHandler.default_content_type # attribute. + # class DirHandler < HttpHandler attr_accessor :default_content_type attr_reader :path -- cgit v1.2.3-24-ge0c7