File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes <bean:message> and jquery Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "<bean:message> and jquery" Watch "<bean:message> and jquery" New topic
Author

<bean:message> and jquery

Naveen puttu
Ranch Hand

Joined: Sep 15, 2009
Posts: 88
Hi

I have a variable timeZone which i get after parsing the xml . i print this value and i see that the value is EST as expected

Now im trying to do as follows



Im using struts, so <bean:message key="timeZone"/> picks the value from the properties file

i get the error message




Am i trying to achieve something impossible
Naveen puttu
Ranch Hand

Joined: Sep 15, 2009
Posts: 88
i basically think that this is achievable , however the value timeZone i get after parsing the xml is text

and bean:message tag key attribute expects a string

am i correct
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60782
    
  65

This has nothing to do with jQuery -- it's a Struts issue. You need to make sure that whatever is generated is valid HTML and javaScript.

Moved to the Struts forum.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

It doesn't really have anything to do with Struts, either; the initial JavaScript being generated is wrong. You need to quote the value--just look at the JavaScript being generated; it's obviously invalid.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: <bean:message> and jquery
 
Similar Threads
set html option value by bean: message key=...
Problem with TimeZone.getDefault().getID() API
anybody know how to get property in a Form?
I want to enable submit button only when i check the checkbox
retrieve value from property file from a variable