Permalink
Browse files

minor corrections in form helpers guide and api docs

  • Loading branch information...
1 parent 5bafead commit cc505e1d33e669cab0ac6e9e749fbd45bdf5d000 @vijaydev vijaydev committed with fxn Jul 19, 2011
@@ -852,7 +852,7 @@ def radio_button(object_name, method, tag_value, options = {})
# some browsers
#
# ==== Examples
- #
+ #
# search_field(:user, :name)
# # => <input id="user_name" name="user[name]" size="30" type="search" />
# search_field(:user, :name, :autosave => false)
@@ -888,7 +888,7 @@ def search_field(object_name, method, options = {})
# Returns a text_field of type "tel".
#
- # telephone_field("user", "phone")
+ # telephone_field("user", "phone")
# # => <input id="user_phone" name="user[phone]" size="30" type="tel" />
def telephone_field(object_name, method, options = {})
@@ -177,12 +177,12 @@ Other form controls worth mentioning are the text area, password input, hidden i
<%= password_field_tag(:password) %>
<%= hidden_field_tag(:parent_id, "5") %>
<%= search_field(:user, :name) %>
-<%= telephone_field(:user, :phone) %>
-<%= url_field(:user, "homepage) %>
+<%= telephone_field(:user, :phone) %>
+<%= url_field(:user, :homepage) %>
<%= email_field(:user, :address) %>
</erb>
-output:
+Output:
<html>
<textarea id="message" name="message" cols="24" rows="6">Hi, nice site</textarea>
@@ -194,8 +194,7 @@ output:
<input id="user_address" size="30" name="user[address]" type="email" />
</html>
-Hidden inputs are not shown to the user, but they hold data like any textual input. Values inside them can be changed with JavaScript. The search, tel, url and email inputs are specified in HTML5 and may receive special handling and/or formatting
-in some user-agents.
+Hidden inputs are not shown to the user, but they hold data like any textual input. Values inside them can be changed with JavaScript. The search, tel, url and email inputs are specified in HTML5 and may receive special handling and/or formatting in some user-agents.
TIP: If you're using password input fields (for any purpose), you might want to configure your application to prevent those parameters from being logged.

0 comments on commit cc505e1

Please sign in to comment.