similar to: rails-i18n and date_select issue

Displaying 20 results from an estimated 5000 matches similar to: "rails-i18n and date_select issue"

2012 Oct 09
8
unexpected should_receive behaviour
Hi, surely I''m missing something... but what!? in my spec I''ve User.should_receive(:find).with("1").and_return(@user) and in my controller User.find(params[:id]) green light... correct... but if I change my controller using another method, for example first: User.first or even User.all I get green light too... I was expecting an error like expected: 1 time
2012 Nov 05
3
DragonFly Object not found in Production
could please anyone help me with this issue? http://stackoverflow.com/questions/13237954/object-not-found-in-production thanks, enrico -- · Enrico Stano · · twitter @enricostano · skype ocirneonats -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to
2012 Oct 15
0
CanCan load_resource get a nil resource
Hi, I''ve opened a question on StackOverflow regarding #load_resources and a create action in UserController: http://stackoverflow.com/questions/12882284/load-resource-get-a-nil-resource Could anyone please give me some hints? thank you! enrico -- · Enrico Stano · · twitter @enricostano · skype ocirneonats -- You received this message because you are subscribed to the Google
2010 Aug 21
2
Rails 3: I18n.locale not set to I18n.default_locale in production
I have an application that uses I18n, but in the first deployment, I don''t want to enable different languages per user/request because there are very few users who all speak german). Therefore I have config.i18n.default_locale = :de in config/ application.rb. I have no code whatsoever to set/change I18n.locale in my app. In development environment, it works as expected: the
2005 Feb 15
5
date_select where to add "class"=>"something"
Hi, I''ve looked on api.rubyonrails.org but I''ve not found how to add to a date_select(object, method, options = {}) a class option to set the class of all the select tags. I''ve tried using "class" => "myclass" in thoose ways: <%= date_select("costo", "data", "class" => "testo" ) %> <%=
2009 Jun 24
3
I18N: allocator undefined for Proc
Hello all, I''m trying to translate my application using the I18N feature and it was working fine until I added a couple of new entries to the en.yml files. Now in every action in my application I always get the following error: TypeError in Account#login Showing app/views/account/login.rhtml where line #2 raised: allocator undefined for Proc Extracted source (around line #2): 1: 2:
2006 Aug 23
11
i18n friendly, plugable Rails Core
In my work with a simple localization plugin, i''m running into a lot of places in the Rails core, where text and other localization specific information is hardcoded. I''ve included some examples in the bottom of this post. It''s hard for an outsider to know, if the hardcoded values are a result of inconsistency in code, or "by design". I hope that we can have
2006 May 05
0
Updating Squirrelmail-i18n dependency
Because of a folder display problem caused by certain character encodings used in some email headers we had previously updated to squirrelmail-1.4.6-1 and installed squirrelmail-i18n-1.4.6-1 to cope. Yum is now trying to update our installation with the latest offical Centos release but there does not seem to be a corresponding squirrelmail-i18n rpm available in any of the repositories which is
2010 Jul 23
0
alias_method_chain with i18n
Hello, I was investigating solutions for i18n with will_paginate and I found a possible solution at http://lawrencesong.net/2009/01/enable-i18n-in-will_paginate-plugin/ The author adds to application_helper.rb the following code: ############################################# include WillPaginate::ViewHelpers def will_paginate_with_i18n(collection, options = {})
2010 Oct 01
1
I18n.with_options bloc executed TWICE
Hi, to avoid putting the whole locale scope on every I18n.t call I''m trying to use a scope, as stated in the doc (http://guides.rubyonrails.org/active_support_core_extensions.html#with_options) I tried with <%= I18n.with_options :locale => :en, :scope => ''portal.visitor_menu'' do |i18n|%> Try <%= i18n.t :fav_songs %> <% end %> But it produce
2012 Oct 10
0
Setting locale directories for I18n
Rails 3.1.3 I would like to apply i18n for my application. Since there are many yml files in config/locales directory, I have made subdirectories so that the maintenance will be easier. For example, config/locales/devise/ date/ top/ ... Each subdirectories contain corresponding locale files that are applied when users change
2010 Jul 10
0
`method_missing': undefined method `i18n' for #<Rails::Railtie::Configuration:0x000001010fce98>
I have recently upgraqded to Ruby 1.9.2-rc1 and reinstalled rails 3 beta 4 with all the dependencies. I have run bundle install in my rails project. Now I am trying to run some tests... My test_helper.rb file looks like this: # test_helper.rb require ''rubygems'' require ''test/unit'' require ''rails/all'' $ gem list i18n (0.4.1, 0.3.7)
2009 Jan 17
2
active_scaffold + i18n
Hello all, I have a project where I''m using active_scaffold and would also like to use i18n over it. While the i18n works fine if I just ignore the active_scaffold, I couldn''t get it running with it. I searched through its docs and googled quite a bit. Can I use i18n with active_scaffold? thanks cheers -- gallois aka Felipe Gallois blog: www.gallois.com.br/blog fanglib
2008 Dec 14
0
Newbee met problems when do some i18n on rails
1. I have download the zh-CN.yml file from http://github.com/svenfuchs/rails-i18n/tree/master/rails locale 2. I have put this zh-CN.yml in to my locales folder. 3. I have modified the enviorment.rb like follow: config.i18n.load_path << Dir[File.join(RAILS_ROOT, ''my'', ''locales'', ''*. {rb,yml}'')] config.i18n.default_locale =
2011 Jul 22
2
ActiveSupport not including i18n?
Went to use ActiveSupport in a gem today and got an error on account of not having i18n installed. Either bundler should be installing i18n along with activesupport or docs need to be updated. quick repro: https://github.com/softwaregravy/repro_active_support_i18n bundle exec irb require ''active_support/all'' detailed steps and error: 1) add to Gemfile require
2011 Jul 22
2
ActiveSupport not including i18n?
Went to use ActiveSupport in a gem today and got an error on account of not having i18n installed. Either bundler should be installing i18n along with activesupport or docs need to be updated. quick repro: https://github.com/softwaregravy/repro_active_support_i18n bundle exec irb require ''active_support/all'' detailed steps and error: 1) add to Gemfile require
2011 Sep 05
1
I18n.locale Setting invalid
I like this set of code: before_filter :set_language def set_language request_language = request.env[''HTTP_ACCEPT_LANGUAGE''] request_language = request_language.nil? ? nil : request_language[/[^,;]+/] I18n.locale = request_language if request_language && File.exist?("#{Rails.root.to_s}/config/locales/#{request_language}.yml") end if i setting
2009 Jan 23
0
NameError: uninitialized constant I18n
Just installed the plugin as described on the link below. http://factore.ca/on-the-floor/11-introducing-has-foreign-language-an-easy-database-internationalization-plugin If i fire up my console and then: I18n.default_locale = "en" i got the error message: NameError: uninitialized constant I18n from
2009 May 03
1
Localizing attributes when using I18n
Currently I''m developing a multilingual app on rails 2.2. I liked very much the idea of Xavier Defrang to provide a locale-aware accessor for the fields that needs a translation: http://defrang.com/articles/2005/12/02/playing-with-rails-i18n I modified code a little to make it work with rails 2.2: def self.localize(*attribute_names) attribute_names.each do |attribute_name|
2010 Apr 05
0
I18n in ruby scripts
Hello, I created a ruby script for my RubyOnRails application that send a mail to my application users. This script is executed using a cron job everyday at midnight. Ok so that part works just great. My problem is that I have to use RubyOnRails I18n system to translate a large part of the emails sent and it doesn''t seems to work (translation is not done). I''m using the