diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 9da044c..db29865 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -19,6 +19,7 @@ require 'forwardable' require 'cgi' +require 'htmlentities' module ApplicationHelper include Redmine::WikiFormatting::Macros::Definitions @@ -739,6 +740,7 @@ module ApplicationHelper link_project = project esc, all, page, title = $1, $2, $3, $5 if esc.nil? + page = decode_html_entities(page) if page =~ /^([^\:]+)\:(.*)$/ identifier, page = $1, $2 link_project = Project.find_by_identifier(identifier) || Project.find_by_name(identifier) @@ -1500,4 +1502,9 @@ module ApplicationHelper name = identifier.gsub(%r{^"(.*)"$}, "\\1") return CGI.unescapeHTML(name) end + + def decode_html_entities(page) + @coder ||= HTMLEntities.new() + @coder.decode(page) + end end