aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2009-03-17 21:01:50 +0100
committerXavier Noria <fxn@hashref.com>2009-03-17 21:01:50 +0100
commite8501a15a84f4c0d894273b0decedf64cce66c76 (patch)
tree6601f27ca44b7d12c84a9bb8c9934ec9c9d17eff
parent485cd69a7b9384a5eb5af1d49945a8bce6286159 (diff)
downloadrails-e8501a15a84f4c0d894273b0decedf64cce66c76.tar.gz
rails-e8501a15a84f4c0d894273b0decedf64cce66c76.tar.bz2
rails-e8501a15a84f4c0d894273b0decedf64cce66c76.zip
clarifies a bit more what's the issue with check boxes and arrays of parameters
-rw-r--r--actionpack/lib/action_view/helpers/form_helper.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/actionpack/lib/action_view/helpers/form_helper.rb b/actionpack/lib/action_view/helpers/form_helper.rb
index 4e1927a897..a59829b23f 100644
--- a/actionpack/lib/action_view/helpers/form_helper.rb
+++ b/actionpack/lib/action_view/helpers/form_helper.rb
@@ -655,7 +655,11 @@ module ActionView
# <% end %>
#
# because parameter name repetition is precisely what Rails seeks to distinguish
- # the elements of the array.
+ # the elements of the array. For each item with a checked check box you
+ # get an extra ghost item with only that attribute, assigned to "0".
+ #
+ # In that case it is preferable to either use +check_box_tag+ or to use
+ # hashes instead of arrays.
#
# ==== Examples
# # Let's say that @post.validated? is 1: