The first line return a RawBlock wrapped in an XDOM block without any metadata. What happens is this:
when the request has outputSyntax=plain the syntax of the generated RawBlock is Plain 1.0 (starting with XWIKI-22738), which leads to an empty output when rendered with the HTML5 renderer
when the outputSyntax request parameter is missing (or if you don't have the changes from XWIKI-22738) the syntax of the generated RawBlock is HTML5 (matching the default output syntax I guess). This leads to the expected output when rendered with the HTML5 renderer
Note that the problem is not visible is you render the template like this:
If you use something like this to request HTML async, then:
you can't simply use the get action, because the HTML is encoded
you can't add outputSyntax=plain because you lose the HTML
Your only option is to write the rendering output directly to the response body and to get the HTML with the get action without outputSyntax=plain.
Thomas MortagneSimon Urli do we need to do something about this? Is this the expected behavior (after XWIKI-22738). Is there a better way to fix XWIKI-22738 without having this side effect?
This message was sent by Atlassian Jira (v9.3.0#930000-sha1:287aeb6)
If image attachments aren't displayed, see this article.