1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Updated docs on auto-indexing #765 [Astinus]

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@848 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
David Heinemeier Hansson 2005-03-06 13:57:16 +00:00
parent 87b55f59dd
commit 00fe726a76

View file

@ -45,6 +45,14 @@ module ActionView
# <input type="submit" value="Save">
# </form>
#
# If the object name contains square brackets the id for the object will be inserted. Example:
#
# <%= textfield "person[]", "name" %>
#
# ...becomes:
#
# <input type="text" id="person_<%= @person.id %>_name" name="person[<%= @person.id %>][name]" value="<%= @person.name %>" />
#
# If the helper is being used to generate a repetitive sequence of similar form elements, for example in a partial
# used by render_collection_of_partials, the "index" option may come in handy. Example:
#