Hi, I am using the tzinfo gem and plugins to manage time zone support in my app. In one of the views I have the following select <%= time_zone_select ''user'', ''time_zone'', TZInfo::Timezone.all.sort, :model => TZInfo::Timezone %> This produces a list of all possible countries, does anyone know of a way to only display the UTC + / - options and not the named places? thanks -- 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On 1/2/08, Scott A S <rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:> I am using the tzinfo gem and plugins to manage time zone support in my > app. > > In one of the views I have the following select > <%= time_zone_select ''user'', ''time_zone'', TZInfo::Timezone.all.sort, > :model => TZInfo::Timezone %> > > This produces a list of all possible countries, does anyone know of a > way to only display the UTC + / - options and not the named places?I''m not familiar with the tzinfo gem but you should be able to use something like this: TZInfo::Timezone.all.sort.collect { |tz| [ tz.name ] } -- Greg Donald http://destiney.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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Possibly Parallel Threads
- Time zone mapping from TimeZone to TZInfo::Timezone
- time_zone_select :priority_zones not working properly
- Some timezone trouble involving tzinfo and postgresql
- Introduction & time_zone_select with mapped TimeZone question
- TZInfo::Timezone problem selected value