Hi Calven.
I’d programmatically create a response and return that, rather than create a separate component . Something like this (warning untested pseudocode):
public WOActionResults downloadJson() { WOResponse response = new WORespnse(); response.setHeader( “application/json” ); response.setContentString( someStringContainingJSON ); return response; }
Every JSON parser I have ever encountered defaults to UTF-8 (as they should, it’s part of the RFC) so you shouldn’t have to specify the encoding.
Cheers, - hugi // Hugi Thordarson
// s. 895-6688
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
|