|
Re: bug in routes ???: msg#00240lang.ruby.rails.core
Hello Greg, 2006/9/25, Greg Hauptmann <greg.hauptmann.ruby@xxxxxxxxx>: > [5] Placing dynamically generated value for :locale in every link_to. Not > ideal from a DRY concept. Example: > link_to 'my link', { :locale => '#{params[:locale]}', :controller > => '/parent/child', :action => 'testaction' } Take a look at default_url_options: http://api.rubyonrails.com/classes/ActionController/Base.html#M000208 That is the best way to implement #5. Hope that helps ! -- François Beausoleil http://blog.teksol.info/ http://piston.rubyforge.org/ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@xxxxxxxxxxxxxxxx To unsubscribe from this group, send email to rubyonrails-core-unsubscribe@xxxxxxxxxxxxxxxx For more options, visit this group at http://groups.google.com/group/rubyonrails-core -~----------~----~----~----~------~----~------~--~---
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: ActiveRecord: private versus protected methods, Mislav Marohnić |
|---|---|
| Next by Date: | Re: Table Definition - Better binary support w/MySQL, DHH |
| Previous by Thread: | Re: bug in routes ???, Greg Hauptmann |
| Next by Thread: | Re: bug in routes ???, Greg Hauptmann |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |