Diff for /loncom/interface/londocs.pm between versions 1.199 and 1.206

version 1.199, 2005/07/26 22:30:20 version 1.206, 2005/09/20 07:52:03
Line 166  sub dumpcourse { Line 166  sub dumpcourse {
  $crs=~s/\_/\//g;   $crs=~s/\_/\//g;
  foreach (keys %replacehash) {   foreach (keys %replacehash) {
     my $newfilename=$title.'/'.$replacehash{$_};      my $newfilename=$title.'/'.$replacehash{$_};
       $newfilename=~s/\.(\w+)$//;
       my $ext=$1;
     $newfilename=&clean($newfilename);      $newfilename=&clean($newfilename);
       $newfilename.='.'.$ext;
     my @dirs=split(/\//,$newfilename);      my @dirs=split(/\//,$newfilename);
     my $path='/home/'.$ca.'/public_html';      my $path='/home/'.$ca.'/public_html';
     my $makepath=$path;      my $makepath=$path;
Line 252  sub exportbutton { Line 255  sub exportbutton {
     return '</td><td bgcolor="#DDDDCC">'.      return '</td><td bgcolor="#DDDDCC">'.
             '<input type="submit" name="exportcourse" value="'.              '<input type="submit" name="exportcourse" value="'.
             &mt('Export Course to IMS').'" />'.              &mt('Export Course to IMS').'" />'.
             &Apache::loncommon::help_open_topic('Docs_Export_Course_Docs');      &Apache::loncommon::help_open_topic('Docs_Export_Course_Docs');
 }  }
   
 sub exportcourse {  sub exportcourse {
Line 656  sub process_content { Line 659  sub process_content {
     my ($count,$curRes,$cdom,$cnum,$symb,$content_file,$href,$copyresult,$tempexport) = @_;      my ($count,$curRes,$cdom,$cnum,$symb,$content_file,$href,$copyresult,$tempexport) = @_;
     my $content_type;      my $content_type;
     my $message;      my $message;
 # find where user is author or co-author  
     my @uploads = ();      my @uploads = ();
     if ($curRes->is_sequence()) {      if ($curRes->is_sequence()) {
         $content_type = 'sequence';          $content_type = 'sequence';
Line 710  sub process_content { Line 712  sub process_content {
         if ($2 eq $env{'user.domain'} && $3 eq $env{'user.name'})  {          if ($2 eq $env{'user.domain'} && $3 eq $env{'user.name'})  {
             $canedit= 1;              $canedit= 1;
         }          }
   # only include problem code where current user is author
         if ($canedit) {          if ($canedit) {
             $$content_file = &replicate_content($cdom,$cnum,$tempexport,$symb,$count,\$message,$href,'resource');              $$content_file = &replicate_content($cdom,$cnum,$tempexport,$symb,$count,\$message,$href,'resource');
         } else {          } else {
Line 1111  sub editor { Line 1114  sub editor {
                 if ($cmd eq 'del') {                  if ($cmd eq 'del') {
     my (undef,$url)=split(':',$Apache::lonratedt::resources[$Apache::lonratedt::order[$idx]]);      my (undef,$url)=split(':',$Apache::lonratedt::resources[$Apache::lonratedt::order[$idx]]);
     if (($url=~m|/+uploaded/\Q$coursedom\E/\Q$coursenum\E/|) &&      if (($url=~m|/+uploaded/\Q$coursedom\E/\Q$coursenum\E/|) &&
  ($url!~/\.(page|sequence|problem|exam|quiz|assess|survey|form|library)$/)) {   ($url!~/\.(page|sequence|problem|exam|quiz|assess|survey|form|library|task)$/)) {
  &Apache::lonnet::removeuploadedurl($url);   &Apache::lonnet::removeuploadedurl($url);
     } else {      } else {
  &Apache::lonratedt::makezombie($Apache::lonratedt::order[$idx]);   &Apache::lonratedt::makezombie($Apache::lonratedt::order[$idx]);

Removed from v.1.199  
changed lines
  Added in v.1.206


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>