Over a million developers have joined DZone.

Rails Helper: Display Flash Hash

·
Rails Helper


	def print_flash
		msg = ''
		flash.each_pair do |type, message|
			text = content_tag(:strong, type.to_s.capitalize) << ": " <<	message
			msg << content_tag(:p, text, :class => "flash #{type}")
		end 
		msg
	end
Topics:

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}