I have a hash.
[% hash = { barney => 4, Wilma => 3, fred => 2, betty => 1 } %]
It is easy to dump the contents of the hash ordered by the keys:
[% FOREACH key = hash.keys.sort %]
[% key %] => [% hash.$key %]
[% END %]
But I'm coming unstuck when I try to do it ordered by the values:
[% FOREACH value = hash.values.nsort %]
[% # key ? %] => [% value %]
[% END %]
Sure, I can find the values, how can I get the keys back?
Andrew
_______________________________________________
templates mailing list
[EMAIL PROTECTED]
http://lists.ourshack.com/mailman/listinfo/templates