-
Bug
-
Resolution: Fixed
-
Low
-
2.10
-
None
If a user macro with an "unprocessed macro body" has a body that contains html, then the html will be rendered in wysiwyg editing and lost when converted back to wiki markup. It should not be lost.
Suppose you have a User macro with the following fields:
Macro name: b
Macro has a body: "Use unprocessed macro body"
Output: Macro generates HTML markup
Template: <b>$body</b>
It's something of a bad idea, because it shouldn't really use an unprocessed body, it should use a wiki macro body, but it is possible, and it will work to make whatever is put inside it as bold. If somebody uses this macro as follows:
{b}<i>text</i>{b}
The macro will work when using wikimarkup, rendering text in bold and italics. When using the rich text editor, the italics will be included in the body and text will render in italics. (They probably should be escaped). When the conversion back to wiki markup happens, an assumption is made that the user macro has an unrendered body and so all html is stripped from it.
The problem seems to be that com.atlassian.renderer.wysiwyg.WysiwygMacroHelper#renderMacroWithoutRenderableBody (in 2.10) doesn't escape html in the body.
- is incorporated by
-
CONFSERVER-6992 Markup umbrella issue - errors switching between modes or rendering escaped content
- Closed
- relates to
-
CONFSERVER-9928 WIki markup containing <tag> elements is erased when switching to the RTE
- Closed