[xwiki-users] how to generate XML from a velocity script page ?
sergiu at xwiki.com
Thu Jun 7 13:43:09 UTC 2012
On 06/07/2012 09:28 AM, mathieu.canzerini at intech.lu wrote:
> Hello everybody,
> i need to use Ajax but i can not generate XML from a velocity script page.
> Here is a piece of my script :
> #set ($out = $response.getOutputStream())
> $out.write("<?xml version='1.0' encoding='ISO-8859-1'?><test>test</test>")
> But my responseXML is null.
> I suppose that it's not the good way to generate XML from velocity.
> Thanks for your help.
> M. Canzerini
See this other thread:
Short summary, you should call flush() and close() on the stream after
you're done writing data to it.
More information about the users