diff options
-rw-r--r-- | railties/guides/source/form_helpers.textile | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/railties/guides/source/form_helpers.textile b/railties/guides/source/form_helpers.textile index 41d8fba3dc..074aea300a 100644 --- a/railties/guides/source/form_helpers.textile +++ b/railties/guides/source/form_helpers.textile @@ -605,9 +605,9 @@ can be replaced with by defining a LabellingFormBuilder class similar to the following: <ruby> -class LabellingFormBuilder < FormBuilder +class LabellingFormBuilder < ActionView::Helpers::FormBuilder def text_field(attribute, options={}) - label(attribute) + text_field(attribute, options) + label(attribute) + super end end </ruby> |