aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_view
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2010-09-23 22:35:08 +0200
committerXavier Noria <fxn@hashref.com>2010-09-23 22:35:08 +0200
commit8c0c815ba711c439cbc4d295c423d5d6ab0bb848 (patch)
tree46ebc98a50a631a8962cb48505f75454cd8f24f1 /actionpack/lib/action_view
parentafdf86e8ee7c64915515e7ad8930efd858fceb43 (diff)
parent5965219ca2230dc46cff2feace19d83b7493f440 (diff)
downloadrails-8c0c815ba711c439cbc4d295c423d5d6ab0bb848.tar.gz
rails-8c0c815ba711c439cbc4d295c423d5d6ab0bb848.tar.bz2
rails-8c0c815ba711c439cbc4d295c423d5d6ab0bb848.zip
resolves rdoc conflict
Diffstat (limited to 'actionpack/lib/action_view')
-rw-r--r--actionpack/lib/action_view/base.rb2
-rw-r--r--actionpack/lib/action_view/helpers/form_helper.rb10
-rw-r--r--actionpack/lib/action_view/helpers/javascript_helper.rb2
-rw-r--r--actionpack/lib/action_view/helpers/prototype_helper.rb8
4 files changed, 12 insertions, 10 deletions
diff --git a/actionpack/lib/action_view/base.rb b/actionpack/lib/action_view/base.rb
index b0a57f47d3..3fa46d0f43 100644
--- a/actionpack/lib/action_view/base.rb
+++ b/actionpack/lib/action_view/base.rb
@@ -153,7 +153,7 @@ module ActionView #:nodoc:
#
# This refreshes the sidebar, removes a person element and highlights the user list.
#
- # See the ActionView::Helpers::PrototypeHelper::GeneratorMethods documentation for more details.
+ # See the ActionView::Helpers::PrototypeHelper::JavaScriptGenerator::GeneratorMethods documentation for more details.
class Base
module Subclasses
end
diff --git a/actionpack/lib/action_view/helpers/form_helper.rb b/actionpack/lib/action_view/helpers/form_helper.rb
index 6ca956f879..0937075edf 100644
--- a/actionpack/lib/action_view/helpers/form_helper.rb
+++ b/actionpack/lib/action_view/helpers/form_helper.rb
@@ -211,7 +211,7 @@ module ActionView
# If you have an object that needs to be represented as a different
# parameter, like a Client that acts as a Person:
#
- # <%= form_for(@post, :as => :client do |f| %>
+ # <%= form_for(@post, :as => :client) do |f| %>
# ...
# <% end %>
#
@@ -228,8 +228,8 @@ module ActionView
# ...
# <% end %>
#
- # Where +@document = Document.find(params[:id])+ and
- # +@comment = Comment.new+.
+ # Where <tt>@document = Document.find(params[:id])</tt> and
+ # <tt>@comment = Comment.new</tt>.
#
# === Unobtrusive JavaScript
#
@@ -656,11 +656,13 @@ module ActionView
InstanceTag.new(object_name, method, self, options.delete(:object)).to_input_field_tag("hidden", options)
end
- # Returns an file upload input tag tailored for accessing a specified attribute (identified by +method+) on an object
+ # Returns a file upload input tag tailored for accessing a specified attribute (identified by +method+) on an object
# assigned to the template (identified by +object+). Additional options on the input tag can be passed as a
# hash with +options+. These options will be tagged onto the HTML as an HTML element attribute as in the example
# shown.
#
+ # Using this method inside a +form_for+ block will set the enclosing form's encoding to <tt>multipart/form-data</tt>.
+ #
# ==== Examples
# file_field(:user, :avatar)
# # => <input type="file" id="user_avatar" name="user[avatar]" />
diff --git a/actionpack/lib/action_view/helpers/javascript_helper.rb b/actionpack/lib/action_view/helpers/javascript_helper.rb
index f392d92e75..cd3a3eac80 100644
--- a/actionpack/lib/action_view/helpers/javascript_helper.rb
+++ b/actionpack/lib/action_view/helpers/javascript_helper.rb
@@ -65,7 +65,7 @@ module ActionView
# //]]>
# </script>
#
- # +html_options+ may be a hash of attributes for the <tt><script></tt>
+ # +html_options+ may be a hash of attributes for the <tt>\<script></tt>
# tag. Example:
# javascript_tag "alert('All is good')", :defer => 'defer'
# # => <script defer="defer" type="text/javascript">alert('All is good')</script>
diff --git a/actionpack/lib/action_view/helpers/prototype_helper.rb b/actionpack/lib/action_view/helpers/prototype_helper.rb
index bc67197e64..300207dfac 100644
--- a/actionpack/lib/action_view/helpers/prototype_helper.rb
+++ b/actionpack/lib/action_view/helpers/prototype_helper.rb
@@ -161,7 +161,7 @@ module ActionView
# JavaScriptGenerator generates blocks of JavaScript code that allow you
# to change the content and presentation of multiple DOM elements. Use
- # this in your Ajax response bodies, either in a <tt><script></tt> tag
+ # this in your Ajax response bodies, either in a <tt>\<script></tt> tag
# or as plain JavaScript sent with a Content-type of "text/javascript".
#
# Create new instances with PrototypeHelper#update_page or with
@@ -224,7 +224,7 @@ module ActionView
#
# You can also use PrototypeHelper#update_page_tag instead of
# PrototypeHelper#update_page to wrap the generated JavaScript in a
- # <tt><script></tt> tag.
+ # <tt>\<script></tt> tag.
module GeneratorMethods
def to_s #:nodoc:
(@lines * $/).tap do |javascript|
@@ -583,10 +583,10 @@ module ActionView
end
# Works like update_page but wraps the generated JavaScript in a
- # <tt><script></tt> tag. Use this to include generated JavaScript in an
+ # <tt>\<script></tt> tag. Use this to include generated JavaScript in an
# ERb template. See JavaScriptGenerator for more information.
#
- # +html_options+ may be a hash of <tt><script></tt> attributes to be
+ # +html_options+ may be a hash of <tt>\<script></tt> attributes to be
# passed to ActionView::Helpers::JavaScriptHelper#javascript_tag.
def update_page_tag(html_options = {}, &block)
javascript_tag update_page(&block), html_options