Forum: Ruby on Rails time_zone_select problem, need difference

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
334ae822566107a2ea2b7a7cb88bd1d6?d=identicon&s=25 brutyn_nick (Guest)
on 2005-11-12 12:49
(Received via mailing list)
hey,

in my rhtml i got this:

<%= time_zone_select ('firm', 'gmt_zone', TZInfo::Timezone.all.sort,
:model =>
TZInfo::Timezone) %>

output is this:

<select id="firm_gmt_zone" name="firm[gmt_zone]"><option
value="Africa/Abidjan">Africa - Abidjan</option>
<option value="Africa/Accra">Africa - Accra</option>
<option value="Africa/Addis_Ababa">Africa - Addis Ababa</option>
<option value="Africa/Algiers">Africa - Algiers</option>
<option value="Africa/Asmera">Africa - Asmera</option>
<option value="Africa/Bamako">Africa - Bamako</option>
.... more options
value="">-------------</option>
</select>

and i want to have the time difference also for each option
ex. <option value="Africa/Accra">Africa - Accra(GTM +6)</option>

i know i have the other list with the differences, but i need TZInfo for
converting times. i just want to change the text for each option not the
value
This topic is locked and can not be replied to.