diff --git a/core/modules/widgets/link.js b/core/modules/widgets/link.js index e75cecd77..8b7e63490 100644 --- a/core/modules/widgets/link.js +++ b/core/modules/widgets/link.js @@ -70,6 +70,7 @@ LinkWidget.prototype.generate = function() { var wikiLinkTemplateMacro = this.renderer.findMacroDefinition("tw-wikilink-template"), wikiLinkTemplate = wikiLinkTemplateMacro ? wikiLinkTemplateMacro.text.trim() : "$uri_encoded$", wikiLinkText = wikiLinkTemplate.replace("$uri_encoded$",encodeURIComponent(this.to)); + wikiLinkText = wikiLinkText.replace("$uri_doubleencoded$",encodeURIComponent(encodeURIComponent(this.to))); this.attributes.href = wikiLinkText; } } else { diff --git a/core/templates/static.template.html.tid b/core/templates/static.template.html.tid index 808d18df9..b523aee8d 100644 --- a/core/templates/static.template.html.tid +++ b/core/templates/static.template.html.tid @@ -1,7 +1,7 @@ title: $:/core/templates/static.template.html type: text/vnd.tiddlywiki-html -\define tw-wikilink-template() static/$uri_encoded$.html +\define tw-wikilink-template() static/$uri_doubleencoded$.html \rules only filteredtranscludeinline transcludeinline
diff --git a/core/templates/static.tiddler.html.tid b/core/templates/static.tiddler.html.tid index 36ba55255..c6054b792 100644 --- a/core/templates/static.tiddler.html.tid +++ b/core/templates/static.tiddler.html.tid @@ -1,6 +1,6 @@ title: $:/core/templates/static.tiddler.html -\define tw-wikilink-template() $uri_encoded$.html +\define tw-wikilink-template() $uri_doubleencoded$.html `