--- rat/map.pm 2007/01/16 21:18:08 1.5 +++ rat/map.pm 2007/01/26 23:37:51 1.6 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # routines for modyfing .sequence and .page files # -# $Id: map.pm,v 1.5 2007/01/16 21:18:08 albertel Exp $ +# $Id: map.pm,v 1.6 2007/01/26 23:37:51 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -440,7 +440,7 @@ sub qtescape { $str=~s/\&\#58\;/\:/g; $str=~s/\&\#39\;/\'/g; $str=~s/\&\#44\;/\,/g; - $str=~s/\"/\&\#34\;/g; + $str=~s/\&\#34\;/\"/g; return $str; } @@ -626,6 +626,8 @@ sub savemap { # --------------------------------------------------------------- Logical input if (($comp[$#comp] eq 'res') || ($comp[$#comp] eq 'zombie')) { $comp[0]=qtescape($comp[0]); + $comp[0] = &HTML::Entities::encode($comp[0],'&<>"'); + $comp[1]=qtescape($comp[1]); if ($comp[2] eq 'true') { if ($comp[1]!~/^http\:\/\//) { @@ -644,7 +646,7 @@ sub savemap { $outstr.=' type="'.$comp[3].'"'; } if ($comp[0] ne '') { - $outstr.=' title="'.&HTML::Entities::encode($comp[0]).'"'; + $outstr.=' title="'.$comp[0].'"'; } $outstr.=" />\n"; } elsif ($comp[$#comp] eq 'cond') {