- foreach my $i ( $view->backupList($share, $dir) ) {
- push(@otherDirs, "<a href=\"$MyURL?action=browse&host=${EscURI($host)}"
- . "&num=$i&share=$shareURI&dir=$pathURI\">$i</a>");
- }
- if ( @otherDirs ) {
- my $otherDirs = join(",\n", @otherDirs);
+ if ( my @otherDirs = $view->backupList($share, $dir) ) {
+ my $otherDirs;
+ foreach my $i ( @otherDirs ) {
+ my $selected;
+ my $showDate = timeStamp2($Backups[$i]{startTime});
+ my $backupNum = $Backups[$i]{num};
+ $selected = " selected" if ( $backupNum == $num );
+ $otherDirs .= "<option value=\"$MyURL?action=browse&host=${EscURI($host)}&num=$backupNum&share=$shareURI&dir=$pathURI\"$selected>#$backupNum - ($showDate)</option>\n";
+ }