Diff for /loncom/publisher/lonrights.pm between versions 1.9 and 1.10

version 1.9, 2003/03/28 01:53:55 version 1.10, 2003/09/22 15:39:53
Line 36  use Apache::lonnet(); Line 36  use Apache::lonnet();
 use Apache::loncommon();  use Apache::loncommon();
 use HTML::LCParser;  use HTML::LCParser;
 use Apache::File;  use Apache::File;
   use Apache::lonlocal;
   
 sub handler {  sub handler {
   
   my $r=shift;    my $r=shift;
   $r->content_type('text/html');    &Apache::loncommon::content_type($r,'text/html');
   $r->send_http_header;    $r->send_http_header;
   
   $r->print(    $r->print(
Line 161  sub handler { Line 162  sub handler {
   my $parser=HTML::LCParser->new(\$contents);    my $parser=HTML::LCParser->new(\$contents);
   my $token;    my $token;
   my $rulecounter=0;    my $rulecounter=0;
   my $colzero=($constructmode?'Edit action':'Rule');    my $colzero=&mt($constructmode?'Edit action':'Rule');
   my %lt=&Apache::loncommon::texthash('ef' => 'Effect',
       'do' => 'Domain',
       'co' => 'Course',
       'se' => 'Section/Group',
       'ro' => 'Role');
 # ---------------------------------------------------------- Start table output  # ---------------------------------------------------------- Start table output
   $r->print(<<ENDSTARTTABLE);    $r->print(<<ENDSTARTTABLE);
 <table border="2">  <table border="2">
     <tr><th>$colzero</th><th>Effect</th><th>Domain</th><th>Course</th>      <tr><th>$colzero</th><th>$lt{'ef'}</th><th>$lt{'do'}</th><th>$lt{'co'}</th>
 <th>Section</th><th>Role</th></tr>  <th>$lt{'se'}</th><th>$lt{'ro'}</th></tr>
 ENDSTARTTABLE  ENDSTARTTABLE
 # --------------------------------------------------------------------- Default  # --------------------------------------------------------------------- Default
 # Fast forward to first rule  # Fast forward to first rule
Line 193  ENDSTARTTABLE Line 199  ENDSTARTTABLE
   }    }
   $r->print('</td><td colspan="4">Default');    $r->print('</td><td colspan="4">Default');
   if (($token->[2]->{'realm'}) || ($token->[2]->{'role'})) {    if (($token->[2]->{'realm'}) || ($token->[2]->{'role'})) {
       $r->print(' - <font color="red">Error! No default set.</font>');        $r->print(' - <font color="red">'.&mt('Error! No default set.').
    '</font>');
   }    }
   $r->print('</td></tr>');    $r->print('</td></tr>');
 # Additional roles  # Additional roles
Line 285  ENDSTARTTABLE Line 292  ENDSTARTTABLE
   $r->print('</table>');    $r->print('</table>');
 # ------------------------------------------------------------ End table output  # ------------------------------------------------------------ End table output
   if ($constructmode) {     if ($constructmode) { 
      $r->print('<input type="submit" name="store" value="Store" /></form>');        $r->print('<input type="submit" name="store" value="'.&mt('Store').'" /></form>'); 
   }    }
   $r->print('</body></html>');    $r->print('</body></html>');
   return OK;      return OK;  

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


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