';
- $prevattempts.='History | ';
+ $prevattempts=&start_data_table().&start_data_table_header_row();
+ $prevattempts.=''.&mt('History').' | ';
foreach my $key (sort(keys(%lasthash))) {
my ($ign,@parts) = split(/\./,$key);
if ($#parts > 0) {
my $data=$parts[-1];
pop(@parts);
- $prevattempts.='Part '.join('.',@parts).' '.$data.' | ';
+ $prevattempts.=''.&mt('Part ').join('.',@parts).' '.$data.' | ';
} else {
if ($#parts == 0) {
$prevattempts.=''.$parts[0].' | ';
@@ -2547,41 +3007,53 @@ sub get_previous_attempt {
}
}
}
+ $prevattempts.=&end_data_table_header_row();
if ($getattempt eq '') {
for ($version=1;$version<=$returnhash{'version'};$version++) {
- $prevattempts.='
---|
Transaction '.$version.' | ';
+ $prevattempts.=&start_data_table_row().
+ ''.&mt('Transaction [_1]',$version).' | ';
foreach my $key (sort(keys(%lasthash))) {
- my $value;
- if ($key =~ /timestamp/) {
- $value=scalar(localtime($returnhash{$version.':'.$key}));
- } else {
- $value=$returnhash{$version.':'.$key};
- }
- $prevattempts.=''.&unescape($value).' | ';
+ my $value = &format_previous_attempt_value($key,
+ $returnhash{$version.':'.$key});
+ $prevattempts.=''.$value.' | ';
}
+ $prevattempts.=&end_data_table_row();
}
}
- $prevattempts.=' Current | ';
+ $prevattempts.=&start_data_table_row().''.&mt('Current').' | ';
foreach my $key (sort(keys(%lasthash))) {
- my $value;
- if ($key =~ /timestamp/) {
- $value=scalar(localtime($lasthash{$key}));
- } else {
- $value=$lasthash{$key};
- }
- $value=&unescape($value);
+ my $value = &format_previous_attempt_value($key,$lasthash{$key});
if ($key =~/$regexp$/ && (defined &$gradesub)) {$value = &$gradesub($value)}
$prevattempts.=''.$value.' | ';
}
- $prevattempts.='
|