![]() |
# Class: Capcode::RenderError [ "README", "AUTHORS", "COPYING", "lib/capcode.rb", nil].each do Capcode.view_html Capcode::Views.view_html Capcode::Helpers.view_html Capcode::HTTPError.view_html Capcode::RenderError.view_html Capcode::RouteError.view_html Capcode::ParameterError.view_html end |
HTTPError help you to create your own 404, 500 and/or 501 response
To create a custom 404 reponse, create a fonction HTTPError.r404 in your application :
module Capcode class HTTPError def r404(f) "#{f} not found :(" end end end
Do the same (r500, r501, r403) to customize 500, 501, 403 errors