Skip to content

Commit

Permalink
mention the alert and notice accessors on the flash
Browse files Browse the repository at this point in the history
  • Loading branch information
tilsammans committed Aug 27, 2010
1 parent 9f4d3a1 commit 76c5693
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions actionpack/lib/action_dispatch/middleware/flash.rb
Expand Up @@ -30,6 +30,11 @@ def flash
# <div class="notice"><%= flash[:notice] %></div>
# <% end %>
#
# Since the +notice+ and +alert+ keys are a common idiom, convenience accessors are available:
#
# flash.alert = "You must be logged in"
# flash.notice = "Successfully created post"
#
# This example just places a string in the flash, but you can put any object in there. And of course, you can put as
# many as you like at a time too. Just remember: They'll be gone by the time the next action has been performed.
#
Expand Down

0 comments on commit 76c5693

Please sign in to comment.