--- rat/map.pm 2007/12/01 03:07:39 1.10 +++ rat/map.pm 2009/02/12 11:35:10 1.13 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # routines for modyfing .sequence and .page files # -# $Id: map.pm,v 1.10 2007/12/01 03:07:39 albertel Exp $ +# $Id: map.pm,v 1.13 2009/02/12 11:35:10 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -265,7 +265,7 @@ sub pastetarget { my $idx=&getresidx($url,$residx); $insertorder[$#insertorder+1]=$idx; my $ext='false'; - if ($url=~/^http\:\/\//) { $ext='true'; } + if ($url=~/^https?\:\/\//) { $ext='true'; } $url=~s/\:/\:/g; $name=~s/\:/\:/g; $resources[$idx]=$name.':'.$url.':'.$ext.':normal:res'; @@ -283,7 +283,7 @@ sub startfinish { # Remove all start and finish foreach (@order) { my ($name,$url,$ext)=split(/\:/,$resources[$_]); - if ($url=~/http\&colon\:\/\//) { $ext='true'; } + if ($url=~/https?\&colon\:\/\//) { $ext='true'; } $resources[$_]=$name.':'.$url.':'.$ext.':normal:res'; } # Garbage collection @@ -456,7 +456,7 @@ sub loadmap { $instr=join('',@content); } if ($instr eq -2) { - $errtext.='Map not loaded: An error occured while trying to load the map.'; + $errtext.='Map not loaded: An error occurred while trying to load the map.'; } elsif ($instr eq '-1') { # Map doesn't exist } elsif ($instr) { @@ -679,7 +679,7 @@ sub savemap { my $result=&Apache::lonnet::finishuserfileupload($2,$1, 'output',$3); if ($result != m|^/uploaded/|) { - $errtext.='Map not saved: A network error occured when trying to save the map. '; + $errtext.='Map not saved: A network error occurred when trying to save the map. '; } } else { if (open(my $fh,">$fn")) {