Item11862: The %ATTCHURL is not preserved during WYSIWYG
Priority: Normal
Current State: Closed
Released In: n/a
Target Release: n/a
Enter into topic:
* [[%ATTACHURL%/TestFileName.pdf][TestFileName.pdf]]: TestFileName.pdf
edit with WYSIWIG, and the %ATTACHURL get converted into
* [[http://example.com/fw/pub/Sandbox/TestTopic4/TestFileName.pdf][TestFileName.pdf]]: TestFileName.pdf
IMO, the macro should be preserved.
--
JozefMojzis - 14 May 2012
Hm... I have "a" fix, not sure if it's a good fix. The expansion appears to happen in TMCE Editor, not in the
WysiwygPlugin. "Protecting" the
http://foswiki.org/pub/Tasks/Item11862 macro is not readily done because the <span needed to protect the macro can't be inserted into the <a link tag.
My solution is to test if the saved url matches the %ATTACHURL% macro and if so, substitute it back. This has the side effect of converting a manually entered link that matches the current topic %ATTACHURL% back to the macro form.
--
GeorgeClark - 14 May 2012
Actually, the fix for
Item11814 broke the roundtrip of %ATTACHURL%. So I've reverted that and tried a different approach.
--
GeorgeClark - 15 May 2012
This was not broken in the 1.1.5 release. No need to document for 1.1.6. Closing the task.
--
GeorgeClark - 02 Jun 2012