Diff for /rat/lonuserstate.pm between versions 1.149.4.1 and 1.150

version 1.149.4.1, 2020/04/07 20:57:02 version 1.150, 2016/01/26 14:30:40
Line 278  sub loadmap { Line 278  sub loadmap {
     }      }
     undef($codechecked);      undef($codechecked);
   
   
     # Handle randomization and random selection      # Handle randomization and random selection
   
     if ($randomize) {      if ($randomize) {
Line 337  sub loadmap { Line 338  sub loadmap {
     @map_ids=&Math::Random::random_permutation(@map_ids);      @map_ids=&Math::Random::random_permutation(@map_ids);
  }   }
   
   
  my $from = shift(@map_ids);   my $from = shift(@map_ids);
  my $from_rid = $lpc.'.'.$from;   my $from_rid = $lpc.'.'.$from;
  $hash{'map_start_'.$uri} = $from_rid;   $hash{'map_start_'.$uri} = $from_rid;
Line 361  sub loadmap { Line 363  sub loadmap {
     $parser = HTML::TokeParser->new(\$instr);      $parser = HTML::TokeParser->new(\$instr);
     $parser->attr_encoded(1);      $parser->attr_encoded(1);
   
     # last parse out the mapalias params.  These provide mnemonic      # last parse out the mapalias params.  Thes provide mnemonic
     # tags to resources that can be used in conditions      # tags to resources that can be used in conditions
   
     while (my $token = $parser->get_token) {      while (my $token = $parser->get_token) {
Line 473  sub parse_resource { Line 475  sub parse_resource {
     } elsif ($turi!~/\.(sequence|page)$/) {      } elsif ($turi!~/\.(sequence|page)$/) {
  $turi='/adm/coursedocs/showdoc'.$turi;   $turi='/adm/coursedocs/showdoc'.$turi;
     }      }
         } elsif ($turi=~ m{^/adm/$match_domain/$match_courseid/\d+/ext\.tool$}) {          } elsif ($turi=~ m{^/adm/$match_domain/$match_courseid/\d+/exttools?$}) {
             $turi='/adm/wrapper'.$turi;              $turi='/adm/wrapper'.$turi;
  } elsif ($turi=~/\S/) { # normal non-empty internal resource   } elsif ($turi=~/\S/) { # normal non-empty internal resource
     my $mapdir=$uri;      my $mapdir=$uri;
Line 706  sub parse_condition { Line 708  sub parse_condition {
 #  Typical attributes:  #  Typical attributes:
 #     to=n      - Number of the resource the parameter applies to.  #     to=n      - Number of the resource the parameter applies to.
 #     type=xx   - Type of parameter value (e.g. string_yesno or int_pos).  #     type=xx   - Type of parameter value (e.g. string_yesno or int_pos).
 #     name=xxx  - Name of parameter (e.g. parameter_randompick or parameter_randomorder).  #     name=xxx  - Name ofr parameter (e.g. parameter_randompick or parameter_randomorder).
 #     value=xxx - value of the parameter.  #     value=xxx - value of the parameter.
   
 sub parse_param {  sub parse_param {
Line 1174  sub readmap { Line 1176  sub readmap {
         &unlink_tmpfiles($fn);          &unlink_tmpfiles($fn);
     }      }
     undef %randompick;      undef %randompick;
     undef %randompickseed;  
     undef %randomorder;  
     undef %randomizationcode;  
     undef %hiddenurl;      undef %hiddenurl;
     undef %encurl;      undef %encurl;
     $retfrid='';      $retfrid='';
Line 1320  sub readmap { Line 1319  sub readmap {
             $lock=1;              $lock=1;
         }          }
         undef %randompick;          undef %randompick;
         undef %randompickseed;  
         undef %randomorder;  
         undef %randomizationcode;  
         undef %hiddenurl;          undef %hiddenurl;
         undef %encurl;          undef %encurl;
   
         $errtext='';          $errtext='';
         $retfrid='';          $retfrid='';
  #   #

Removed from v.1.149.4.1  
changed lines
  Added in v.1.150


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