From bbbe9711ebea6b318499f3f04824ca8695d455a5 Mon Sep 17 00:00:00 2001 From: Nicolas Bally Date: Thu, 31 Aug 2017 17:04:16 +0200 Subject: [PATCH] 404 --- config/application.rb | 4 ++- config/routes.rb | 1 + public/404.html | 58 ------------------------------------------- 3 files changed, 4 insertions(+), 59 deletions(-) delete mode 100644 public/404.html diff --git a/config/application.rb b/config/application.rb index 9f14f3a..a9f0f57 100644 --- a/config/application.rb +++ b/config/application.rb @@ -21,6 +21,8 @@ module CMSnb config.i18n.default_locale = :fr config.assets.precompile += %w(public.css public.js admin.css admin.js admin_auth.css connexion.js student.css student.js) - + + config.exceptions_app = self.routes + end end diff --git a/config/routes.rb b/config/routes.rb index 621411b..179e43e 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -5,6 +5,7 @@ CMSnb::Application.routes.draw do # You can have the root of your site routed with "root" + match "/404", :to => "public/menu_items#show", :via => :all, :defaults => {:url => "404", :f => "html"} get 'nouvelles-pelerines.html' => "public/articles#index", :as => "public_articles" diff --git a/public/404.html b/public/404.html deleted file mode 100644 index a0daa0c..0000000 --- a/public/404.html +++ /dev/null @@ -1,58 +0,0 @@ - - - - The page you were looking for doesn't exist (404) - - - - - -
-

The page you were looking for doesn't exist.

-

You may have mistyped the address or the page may have moved.

-
-

If you are the application owner check the logs for more information.

- -