This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
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


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’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: Creating JSON object in struts2
 
It's not a secret anymore!