diff options
author | Xavier Noria <fxn@hashref.com> | 2010-09-14 20:07:29 +0200 |
---|---|---|
committer | Xavier Noria <fxn@hashref.com> | 2010-09-14 20:07:29 +0200 |
commit | dd6efe98b62946ae4d4df0672292449226b8d6fc (patch) | |
tree | 8854f46462eacc6355ca6f8da3d7111a57e036ea /actionpack/lib | |
parent | 9362ef6e21e44341a5ef9d85ece468f407357ceb (diff) | |
parent | b59a8d42c300651ad3384d4dab326454c088cbcc (diff) | |
download | rails-dd6efe98b62946ae4d4df0672292449226b8d6fc.tar.gz rails-dd6efe98b62946ae4d4df0672292449226b8d6fc.tar.bz2 rails-dd6efe98b62946ae4d4df0672292449226b8d6fc.zip |
Merge remote branch 'docrails/master'
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_view/helpers/javascript_helper.rb | 3 | ||||
-rw-r--r-- | actionpack/lib/action_view/helpers/prototype_helper.rb | 16 |
2 files changed, 10 insertions, 9 deletions
diff --git a/actionpack/lib/action_view/helpers/javascript_helper.rb b/actionpack/lib/action_view/helpers/javascript_helper.rb index 84f53b842c..f392d92e75 100644 --- a/actionpack/lib/action_view/helpers/javascript_helper.rb +++ b/actionpack/lib/action_view/helpers/javascript_helper.rb @@ -65,7 +65,8 @@ module ActionView # //]]> # </script> # - # +html_options+ may be a hash of attributes for the <script> tag. Example: + # +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 b600666536..bc67197e64 100644 --- a/actionpack/lib/action_view/helpers/prototype_helper.rb +++ b/actionpack/lib/action_view/helpers/prototype_helper.rb @@ -161,8 +161,8 @@ 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 <script> tag or as plain - # JavaScript sent with a Content-type of "text/javascript". + # 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 # ActionController::Base#render, then call +insert_html+, +replace_html+, @@ -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 - # <script> tag. + # <tt><script></tt> tag. module GeneratorMethods def to_s #:nodoc: (@lines * $/).tap do |javascript| @@ -582,12 +582,12 @@ module ActionView JavaScriptGenerator.new(self, &block).to_s.html_safe end - # Works like update_page but wraps the generated JavaScript in a <script> - # tag. Use this to include generated JavaScript in an ERb template. - # See JavaScriptGenerator for more information. + # Works like update_page but wraps the generated JavaScript in a + # <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 <script> attributes to be passed - # to ActionView::Helpers::JavaScriptHelper#javascript_tag. + # +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 end |