Created
September 12, 2011 23:47
-
-
Save kenzie/1212791 to your computer and use it in GitHub Desktop.
Rails 3 wrap field errors in spans
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# wrap errors in span | |
config.action_view.field_error_proc = Proc.new { |html_tag, instance| "<span class=\"field_with_errors\">#{html_tag}</span>".html_safe } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment