INCLUDE_DATA

Entries from June 2008 ↓

Hey! Where’s my firebug highlighting??

Just installed firefox 3? Missing firebug highlighting? I guess you probably went to http://getfirebug.com and only saw the link for 1.0?

Fret not, the solution is here: https://addons.mozilla.org/en-US/firefox/addon/1843. Firebug 1.2 beta. The release version should be coming out in a couple of days.

vendor/rails/actionpack/lib/action_view/helpers/date_helper.rb:602:in `date_or_time_select’

Am I the only person in the world with this problem? I searched all over the web for a fix, but no one was even talking about it. The error I get is:

ArgumentError in My/profiles#show
wrong number of arguments (2 for 1)

I am running Rails 2.1, and putting a run-of-the-mill date_select crashes with the error shown in the title. I scratched my head at first, then banged it against the wall. I don’t know how this could be broken, but here is how I monkey-patched it.

Create a file in config/initializers and call it anythingyouwant.rb, and paste this in:

module ActionView
  module Helpers
    class InstanceTag #:nodoc:
      def to_date_select_tag(options = {}, html_options = {})
        date_or_time_select(options.merge(:discard_hour => true))
      end
    end
  end
end

That should fix it.