HTML-escaping of error and info messages
This commit is contained in:
parent
757e58b94f
commit
7be6cbecba
3 changed files with 19 additions and 4 deletions
|
@ -106,6 +106,21 @@ class ApplicationController < ActionController::Base
|
|||
end
|
||||
end
|
||||
|
||||
def rescue_action_in_public(exception)
|
||||
render_text <<-EOL
|
||||
<html>
|
||||
<body>
|
||||
<p>There was a controller specific error processing your request.</p>
|
||||
<!-- \n#{exception}\n#{exception.backtrace.join("\n")}\n -->
|
||||
</body>
|
||||
</html>
|
||||
EOL
|
||||
end
|
||||
|
||||
def local_request?
|
||||
false
|
||||
end
|
||||
|
||||
def return_to_last_remembered
|
||||
# Forget the redirect location
|
||||
redirect_target, @session[:return_to] = @session[:return_to], nil
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue