Diff for /loncom/publisher/lonunauthorized.pm between versions 1.6 and 1.10

version 1.6, 2006/12/06 22:22:39 version 1.10, 2011/06/07 18:05:08
Line 54  sub handler { Line 54  sub handler {
 # figure out what went wrong  # figure out what went wrong
   
     if ($ownerdomain) {      if ($ownerdomain) {
  $r->print('<h1>'.&mt('Choose another server').'</h1><p>'.   $r->print('<p class="LC_error">'
 &mt('The constuction space for this resource is located on another server.').                   .&mt('The construction space for this resource is located on another server.')
 '</p>');                   .'</p>'
                    .'<p>'
                    .&mt('Choose another server.')
                    .'</p>');
         my $ownerhome=&Apache::lonnet::homeserver($ownername,$ownerdomain);          my $ownerhome=&Apache::lonnet::homeserver($ownername,$ownerdomain);
         unless ($ownerhome eq 'no_host') {          unless ($ownerhome eq 'no_host') {
     $r->print(      $r->print('<p>'
  "<p>".&mt('Please log into')." <tt>".$Apache::lonnet::hostname{$ownerhome}.                       .&mt('Please log into [_1] to edit.'
  "</tt> ".&mt('to edit.')."</p>");                           ,'<tt>'.&Apache::lonnet::hostname($ownerhome).'</tt>')
                        .'</p>');
         }          }
       } elsif (!$env{'request.editurl'}) {
           $r->print('<p class="LC_error">'
                    .&mt('There may be a problem with the filename, e.g., you may be attempting to edit a versioned file (files in construction may not include a version number in front of the extension).')
                    .'</p>');
     } else {      } else {
         $r->print(          $r->print('<p class="LC_error">'
             "<h1>".                   .&mt('You do not have authoring privileges for this resource')
  &mt("You do not have authoring privileges for this resource")."</h1>");                   .'</p>');
         my ($realownername)=          my ($realownername)=
     ($env{'request.editurl'}=~m{/(?:~|priv/|home/)($LONCAPA::username_re)});      ($env{'request.editurl'}=~m{/(?:~|priv/|home/)($LONCAPA::username_re)});
         my $realownerhome=          my $realownerhome=
     &Apache::lonnet::homeserver($realownername,      &Apache::lonnet::homeserver($realownername,
  $r->dir_config('lonDefDomain'));   $r->dir_config('lonDefDomain'));
         unless ($realownerhome eq 'no_host') {          unless ($realownerhome eq 'no_host') {
     $r->print("<p>".&mt('Contact')." ".              my $plainname=&Apache::loncommon::plainname($realownername,$r->dir_config('lonDefDomain'));
     &Apache::loncommon::aboutmewrapper(              my $user=$realownername.':'.$r->dir_config('lonDefDomain');
      &Apache::loncommon::plainname($realownername,              my $userlink=&Apache::loncommon::aboutmewrapper(
                                $r->dir_config('lonDefDomain')).' ('.                               $plainname.' ('.$user.')'
                                $realownername.&mt(' at ').                              ,$realownername
                                $r->dir_config('lonDefDomain').')',                              ,$r->dir_config('lonDefDomain'));
        $realownername,$r->dir_config('lonDefDomain')).      $r->print('<p>'
            ' for access.</p>');                       .&mt('Contact [_1] for access.',$userlink)
                        .'</p>');
         }          }
     }      }
           

Removed from v.1.6  
changed lines
  Added in v.1.10


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