diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2010-01-08 11:48:38 -0800 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2010-01-08 11:49:12 -0800 |
commit | 188d52165bc9184a143a468ee951981d159dbea6 (patch) | |
tree | c956c450c3d39f1724c174eef490987b5c71d37d /actionpack/lib | |
parent | 5ea130943eb27586272ecebb060ff1475cadbed6 (diff) | |
download | rails-188d52165bc9184a143a468ee951981d159dbea6.tar.gz rails-188d52165bc9184a143a468ee951981d159dbea6.tar.bz2 rails-188d52165bc9184a143a468ee951981d159dbea6.zip |
Fixed that much of DateHelper wouldn't return html_safe? strings [DHH]
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_view/helpers/date_helper.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/actionpack/lib/action_view/helpers/date_helper.rb b/actionpack/lib/action_view/helpers/date_helper.rb index 4b51dc7856..34f38b0a8a 100644 --- a/actionpack/lib/action_view/helpers/date_helper.rb +++ b/actionpack/lib/action_view/helpers/date_helper.rb @@ -616,7 +616,7 @@ module ActionView build_selects_from_types(order) else - "#{select_date}#{@options[:datetime_separator]}#{select_time}" + "#{select_date}#{@options[:datetime_separator]}#{select_time}".html_safe! end end @@ -835,7 +835,7 @@ module ActionView select_html << prompt_option_tag(type, @options[:prompt]) + "\n" if @options[:prompt] select_html << select_options_as_html.to_s - content_tag(:select, select_html, select_options) + "\n" + (content_tag(:select, select_html, select_options) + "\n").html_safe! end # Builds a prompt option tag with supplied options or from default options @@ -860,12 +860,12 @@ module ActionView # build_hidden(:year, 2008) # => "<input id="post_written_on_1i" name="post[written_on(1i)]" type="hidden" value="2008" />" def build_hidden(type, value) - tag(:input, { + (tag(:input, { :type => "hidden", :id => input_id_from_type(type), :name => input_name_from_type(type), :value => value - }) + "\n" + }) + "\n").html_safe! end # Returns the name attribute for the input tag @@ -896,7 +896,7 @@ module ActionView separator = separator(type) unless type == order.first # don't add on last field select.insert(0, separator.to_s + send("select_#{type}").to_s) end - select + select.html_safe! end # Returns the separator for a given datetime component |