aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb
diff options
context:
space:
mode:
authoraditya-kapoor <aditya.kapoor@vinsol.com>2013-09-01 18:05:04 +0530
committeraditya-kapoor <aditya.kapoor@vinsol.com>2013-09-01 18:05:04 +0530
commit6b9b0767bf480d53029afeb3f8e86f66e933fb41 (patch)
tree62a76c76b8fce484d8a258aceb14ac475f2c94a8 /actionpack/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb
parentb27c40637aaf2549f91faec8e87f6d4afa9a7380 (diff)
parentab0cbff07ebb5df8c9354fa2b3fd9984e039d2c6 (diff)
downloadrails-6b9b0767bf480d53029afeb3f8e86f66e933fb41.tar.gz
rails-6b9b0767bf480d53029afeb3f8e86f66e933fb41.tar.bz2
rails-6b9b0767bf480d53029afeb3f8e86f66e933fb41.zip
Merge branch 'master' of github.com:lifo/docrails
Diffstat (limited to 'actionpack/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb')
-rw-r--r--actionpack/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb30
1 files changed, 30 insertions, 0 deletions
diff --git a/actionpack/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb b/actionpack/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb
new file mode 100644
index 0000000000..7e9cedb95e
--- /dev/null
+++ b/actionpack/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb
@@ -0,0 +1,30 @@
+<header>
+ <h1>Routing Error</h1>
+</header>
+<div id="container">
+ <h2><%= h @exception.message %></h2>
+ <% unless @exception.failures.empty? %>
+ <p>
+ <h2>Failure reasons:</h2>
+ <ol>
+ <% @exception.failures.each do |route, reason| %>
+ <li><code><%= route.inspect.delete('\\') %></code> failed because <%= reason.downcase %></li>
+ <% end %>
+ </ol>
+ </p>
+ <% end %>
+
+ <%= render template: "rescues/_trace" %>
+
+ <% if @routes_inspector %>
+ <h2>
+ Routes
+ </h2>
+
+ <p>
+ Routes match in priority from top to bottom
+ </p>
+
+ <%= @routes_inspector.format(ActionDispatch::Routing::HtmlTableFormatter.new(self)) %>
+ <% end %>
+</div>