'. + &mt('No such directory: [_1]',''.$dir.''). + '
'. &Apache::loncommon::end_page()); } @@ -1195,34 +639,42 @@ sub viewmap { my ($r,$url,$adv,$errtext)=@_; $r->print( &Apache::loncommon::start_page('Edit Content of a Map'). - &Apache::loncommon::help_open_menu('','','','',6,'RAT'). + &Apache::loncommon::help_open_menu('','',6,'RAT'). &buttons($adv)); if ($errtext) { - $r->print($errtext.''.$url.'
'); if ($adv) { - $r->print(''.&mt('Map contents are not shown in order.').'
'.&mt('Type').' | '. - ''.&mt('Title in map').' | '. - ''.&mt('Filename of resource').' | '. - ''.&mt('Link to published resource').' | '. - ''.&mt('Link to resource in Construction Space').' | '. - ''.&mt('Type').' | ' + .''.&mt('Title in map').' | ' + .''.&mt('Filename of resource').' | ' + .''.&mt('Link to published resource').' | ' + .''.&mt('Link to resource in Construction Space').' | ' + .&Apache::loncommon::end_data_table_header_row() + ); + foreach (&LONCAPA::map::attemptread(&Apache::lonnet::filelocation('',$url))) { if (defined($_)) { $idx++; my ($title,$url,$cond)=split(/\:/,$_); if ($cond eq 'cond') { next; } - $title=~s/\&colon\;/\:/g; - $url=~s/\&colon\;/\:/g; + $title= &LONCAPA::map::qtescape($title); + $url = &LONCAPA::map::qtescape($url); unless ($title) { $title=(split(/\//,$url))[-1] }; unless ($title) { $title=''.&mt('Empty').''; } - my $resurl = &Apache::lonratsrv::qtescape($url); + my $resurl = $url; my $resfilepath = $Apache::lonnet::perlvar{'lonDocRoot'}.$resurl; my $filename; if ($resurl =~ m#/([^/]+)$#) { @@ -1230,23 +682,34 @@ sub viewmap { } my $cstrurl = $resurl; $cstrurl =~ s#^/res/[^/]+/([^/]+)/#/priv/$1/#; - my $bgcol = $idx%2; - $r->print('
---|---|---|---|---|---|---|---|---|
'. - ' | '.&Apache::lonratsrv::qtescape($title). - ' | '.$filename.' | '); + $r->print(&Apache::loncommon::start_data_table_row() + .' | ' + .'' + .' | ' + .'' + .&HTML::Entities::encode(&LONCAPA::map::qtescape($title)) + .' | ' + .''.$filename.' | ' + .'' + ); if ($url) { $r->print(''.&mt('Resource space').''); + } else { + $r->print(' '); } $r->print(' | '); if ($url) { $r->print(''. &mt('Construction space').''); + } else { + $r->print(' '); } - $r->print(' |