Skip to content

Commit

Permalink
Item13495: Don't unescape Image URLs
Browse files Browse the repository at this point in the history
This is a partial fix.  Seems to fix conventional utf-8 topics &
attachment neames.  But still don't have the ability to handle and
"reverse" SCRIPTURL{"arguments"}%
  • Loading branch information
gac410 committed Jul 3, 2015
1 parent ff72a0e commit 95111ee
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions WysiwygPlugin/lib/Foswiki/Plugins/WysiwygPlugin/Handlers.pm
Expand Up @@ -310,17 +310,11 @@ sub _populateVars {
local $Foswiki::Plugins::WysiwygPlugin::recursionBlock =
1; # block calls to beforeCommonTagshandler

# Item9973: We call CGI::unescape() on the expanded value, because the
# content of the src attribute on an img tag is received from WYSIWYG that
# way. Without this expandVarsInURL can only match webs, topics, attachments
# named with ascii characters (international characters fail match).
my @exp = split(
/\0/,
CGI::unescape(
Foswiki::Func::expandCommonVariables(
join( "\0", @VARS ),
$opts->{topic}, $opts->{web}
)
Foswiki::Func::expandCommonVariables(
join( "\0", @VARS ),
$opts->{topic}, $opts->{web}
)
);

Expand Down

0 comments on commit 95111ee

Please sign in to comment.