Diff for /loncom/interface/spreadsheet/Spreadsheet.pm between versions 1.19 and 1.21

version 1.19, 2003/07/16 16:48:51 version 1.21, 2003/08/26 19:14:06
Line 794  sub expandnamed { Line 794  sub expandnamed {
  my @vars=split(/\W+/,$formula);   my @vars=split(/\W+/,$formula);
         my %values=();          my %values=();
  foreach my $varname ( @vars ) {   foreach my $varname ( @vars ) {
             if ($varname=~/\D/) {              if ($varname=~/^(parameter|stores|timestamp)/) {
                $formula=~s/$varname/'$c{\''.$varname.'\'}'/ge;                  $formula=~s/$varname/'$c{\''.$varname.'\'}'/ge;
                $varname=~s/$var/\([\\w:\\- ]\+\)/g;                 $varname=~s/$var/\([\\w:\\- ]\+\)/g;
        foreach (keys(%{$self->{'constants'}})) {         foreach (keys(%{$self->{'constants'}})) {
   if ($_=~/$varname/) {    if ($_=~/$varname/) {
Line 1217  sub html_editable_cell { Line 1217  sub html_editable_cell {
     #      #
     # The encoding string "^A-blah" is placed in []'s inside a regexp, so       # The encoding string "^A-blah" is placed in []'s inside a regexp, so 
     # we specify the characters we want left alone by putting a '^' in front.      # we specify the characters we want left alone by putting a '^' in front.
     $formula = &HTML::Entities::encode($formula,"^A-z0-9 !#\$%-;=?~");      $formula = &HTML::Entities::encode($formula,'^A-z0-9 !#$%-;=?~');
       # HTML::Entities::encode does not catch everything - we need '\' encoded
       $formula =~ s/\\/&\#092/g;
     # Escape it again - this time the only encodable character is '&'      # Escape it again - this time the only encodable character is '&'
     $formula =~ s/\&/\&/g;      $formula =~ s/\&/\&/g;
     # Glue everything together      # Glue everything together

Removed from v.1.19  
changed lines
  Added in v.1.21


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