# Make list of ranks. (Relegation is handled specially.)
my @ranks = ();
for my $i (1..$num_games) {
- push @ranks, { 'th' => "$i." };
+ push @ranks, { 'th' => wloh_common::get_ordinal($i, $locale) };
}
my @players = ();
print CGI->header(-type=>'text/html; charset=utf-8', -expires=>'+5m');
wloh_common::process_template('scenario-not-found', $locale, {
'#nick' => $player_name,
- '#rank' => sprintf("%d.", $match_position + 1)
+ '#rank' => wloh_common::get_ordinal($match_position + 1, $locale)
});
} else {
print CGI->header(-type=>'text/html; charset=utf-8', -expires=>'+5m');
wloh_common::process_template('scenario', $locale, {
'#nick' => $player_name,
- '#rank' => sprintf("%d.", $match_position + 1),
+ '#rank' => wloh_common::get_ordinal($match_position + 1, $locale),
'#results' => \@scenario
});
}