Get the tools you need to learn Java skills fast!
Video tutorials, eBooks, hands-on lab exercises, sample code.
Get started
The moose likes Struts and the fly likes Creating JSON object in struts2 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Software Craftsman this week in the Agile forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Creating JSON object in struts2" Watch "Creating JSON object in struts2" New topic
Author

Creating JSON object in struts2

James Peter
Ranch Hand

Joined: Sep 15, 2010
Posts: 115
Hi,

below is code in jsp



The string which comes in globalErrorMessage is

below is code in javascript



then I am getting below error.



Please let me know how to avoid this error.

if I put directly in jsp without using <s:property> then It is not showing any error.

Rgds
Peter
James Peter
Ranch Hand

Joined: Sep 15, 2010
Posts: 115
I found that we just need to add escape=false.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Creating JSON object in struts2