version 1.85, 2014/04/06 18:59:20
|
version 1.86, 2024/11/16 02:41:05
|
Line 327 sub initialize_safe_space {
|
Line 327 sub initialize_safe_space {
|
$safeeval = new Safe(shift); |
$safeeval = new Safe(shift); |
my $safehole = new Safe::Hole; |
my $safehole = new Safe::Hole; |
$safeeval->permit("entereval"); |
$safeeval->permit("entereval"); |
|
$safeeval->permit("hintseval"); |
$safeeval->permit(":base_math"); |
$safeeval->permit(":base_math"); |
$safeeval->permit("sort"); |
$safeeval->permit("sort"); |
$safeeval->deny(":base_io"); |
$safeeval->deny(":base_io"); |
Line 1351 sub html_editable_cell {
|
Line 1352 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 |
# HTML::Entities::encode does not catch everything - we need '\' encoded |
$formula =~ s/\\/&\#092/g; |
$formula =~ s/\\/&\#092/g; |
# Escape it again - this time the only encodable character is '&' |
# Escape it again - this time the only encodable character is '&' |