ability to "sort by keys" when we use TMPL_EACH.I've thought about that. I was actually thinking about to sort by default, so I would change it internally to a loop over keys(). One wouldn't use the unsorted output anyway in production, I guess. What about an attribute CMP which can have the values num or alpha?
edit: I just coded it, it's an easy change.
<%each hash sort=num %>...
Now one
would probably like to have the possibility to reverse
the sort order and to sort by values. I'm open to any suggestions on this.
In reply to Re^2: HTML::Template::Compiled - TMPL_EACH
by tinita
in thread HTML::Template::Compiled - TMPL_EACH
by mmanso
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |