Hi all, I am having a problem at the moment with my code in which if I incase my routes with scope ''(:locale)'' do buy I get the error controller missing, any ideas why? Games::Application.routes.draw do scope ''(:locale)'' do get "game_interest/new" get "rules/index" get "feedback/index" get "help/index" get "log_in" => "sessions#new", :as => "log_in" get "log_out" => "sessions#destroy", :as => "log_out" get "sign_up" => "users#new", :as => "sign_up" get "home/index" get "about/index" resources :feedbacks resources :password_resets resources :contact_messages resources :wishlists resources :searches resources :help resources :users resources :sessions resources :games do post ''email'', :on => :member post ''gensearch'', :on => :member post ''consearch'', :on => :member end root :to => ''home#index'' end end I have the following in my application_controller before_filter :set_i18n_locale_from_params def set_i18n_locale_from_params if params[:locale] if I18n.available_locales.include?(params[:locale].to_sym) I18n.locale = params[:locale] else flash.now[:notice] "#{params[:locale]} translation not available" logger.error flash.now[:notice] end end end def default_url_options { :locale => I18n.locale } end -- Posted via http://www.ruby-forum.com/. -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Can you paste the exact error that you are getting? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/KQzCf8AuYtoJ. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Hi, I am receiving the following error: ArgumentError missing :controller Rails.root: C:/Users/Christopher/Favorites/safety/safety 11/games Application Trace | Framework Trace | Full Trace config/routes.rb:4:in `block (2 levels) in <top (required)>'' config/routes.rb:3:in `block in <top (required)>'' config/routes.rb:1:in `<top (required)>'' This error occurred while loading the following files: C:/Users/Christopher/Favorites/safety/safety 11/games/config/routes.rb -- Posted via http://www.ruby-forum.com/. -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
No worries, solved. -- Posted via http://www.ruby-forum.com/. -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.