Páginas Dinâmicas de Erro em Rails com Goalie
Upcoming SlideShare
Loading in...5
×
 

Páginas Dinâmicas de Erro em Rails com Goalie

on

  • 1,423 views

Palestra rápida apresentando o Goalie, um plugin Rails baseado em Engines e Rack para

Palestra rápida apresentando o Goalie, um plugin Rails baseado em Engines e Rack para

Statistics

Views

Total Views
1,423
Views on SlideShare
1,423
Embed Views
0

Actions

Likes
1
Downloads
2
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as OpenOffice

Usage Rights

CC Attribution-ShareAlike LicenseCC Attribution-ShareAlike License

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Páginas Dinâmicas de Erro em Rails com Goalie Páginas Dinâmicas de Erro em Rails com Goalie Presentation Transcript

  • Páginas dinâmicas de erro em Rails com Goalie Helder Ribeiro
  •  
  •  
  •  
  •  
  • public/400.html public/500.html public/400.pt-BR.html public/500.pt-BR.html
  • Conteúdo dinâmico?
  •  
  • $ gem install goalie # config/application.rb require 'goalie/rails' Seus problemas se acabaram!
  • # goalie/rails module Goalie class Engine < Rails::Engine initializer &quot;goalie.add_middleware&quot; do |app| app.middleware.delete 'ShowExceptions' app.middleware.use Goalie::CustomErrorPages end end end
  • app/views/public_errors/forbidden.html .erb app/views/public_errors/not_found.html .erb … app/views/local_errors/
  • class PublicErrorsController < ApplicationController end
  • class PublicErrorsController < ApplicationController # 404 def not_found @posts = Post.find_latest end end
  •  
  • github.com/obvio171/goalie (MIT license) @obvio171 [email_address]