Migration from struts 1.1 to 1.3

being the rookie that i am , I have no idea how to upgrade from struts 1.1 to 1.3 . so , can any one please help me with a step by step method

Struts 2 field validator thread safety

Marshall,

On 7/15/2010 9:27 AM, Marshall Gunter wrote:

That depends on what you want to do with them. Are you writing your own, or are you critiquing the existing validator implementations?

- -chris

Help with Ajax, Struts & Exception Handling

Hi

I’m making an ajax call to my action, driven by Jquery that refreshes itself every 5 seconds. The code snippet in my jsp file looks like;

var auto_refresh = setInterval( function () { $(‘#div2′).load(‘service-menu-perform-ajax?id=‘).fadeIn(“slow”); }, 5000);

and under normal conditions it works fine. However, as part of the processing my action makes a database call. If the database is not available for any reason, my action throws an exception. In this situation I want to stop the “auto refreshing div” and re-direct to an error page.

I have tried sending a different response if the exception has been thrown that simply contains

alert(‘Stopping’); clearInterval(auto_refresh);

but it’s not executing. Could someone be kind enough to show me how I can stop the polling from the server side?

Regards

Struts 2 custom JSP-tags encoding

Hi, Have an encoding problem when writing custom struts 2 (jsp) tags. We have all our source file UTF-8 encoded and get strange outputs from our tags when using ie. “ÅÄÖ”. Traced it down to JspTemplateEngine which is using org.apache.struts2.components.Include.include(..). The include(..) methods looks after a “defaultEncoding” which is supposed to be injected with “struts.i18n.encoding”. The thing is that JspTemplateEngine is using Include.include(..) statically and thus “struts.i18n.encoding” is never injected.

Is this a bug? Anyone had similar problems?

Regards, Carljohan

Struts 1 binding vulnerability

Open a JIRA ticket and submit a patch. We welcome help from the community.

On Mon, Jul 12, 2010 at 2:06 PM, Zheng, Xiahong wrote:

Weird problem with struts tags

Thanks Greg (and Ken). I appreciate the comments and will get around to updating this code at some point. However I believe these errors to be a symptom of a deeper problem as this code WAS – and still is on some servers – working. I am also getting other strange errors in code which was previously working (such as hibernate PropertyAccessException). I can check out older released versions of the app and they still work on the production and integration servers but I get these errors (and more) on my development machine. I am therefore trying to find out what has changed to produce these errors, and why they are only produced in certain environments.

The same versions of OGNL (ognl-2.6.11.jar) is being used in both environments. As I said, the exact same war file dropped into works on one server but not on another. Further more, it used to work in the environments in which it is now broken. There has also been no java/tomcat/etc updates (that I am aware of) that could have caused this. I am completely flummoxed by this! Any further help much appreciated.

On 2 Jul 2010, at 19:46, Greg Lindholm wrote:

Passing Value through Radio Buttons in struts

Hi, I have a bit of a problem and would appreciate some help!

I am creating a page that takes in a name and a text and runs an algo on the text and then asks for user feedback.

I use radio Buttons to ask for the feedback (Positive or Negative)

Therein lies the catch.. I am not able to pass the value from the radio button onto the bean and hence to the actionclass.

The code for the Part of the radio button is as follows:

According to you does the document express Positive or Negative sentiment?

Positive Negative I have defined a getter and setter method in my bean (using a string type) But it does not seem to get the value as if I try and display it it displays NULL..

I would really appreciate some help Thanks in hope!

Struts time picker does not render in IE7/IE8

Hi friends….any suggesstions?

Regards John

Creating Sub-Domains from Struts 2 application

Dear List member,

I understand this is not a single struts issue. It is combination of many,

What i want is the application to create sub-domain for each users automatically like the site

https://username.tactilecrm.com/welcome/

or

http://tactilecrm.com/

In this site you register for free and your username is created as a sub-domain.

Regards,

Amol Ghotankar

On Tue, Jun 29, 2010 at 2:06 PM, Gustavo Felisberto < gustavo.felisberto@wit-software.com> wrote:

IMPORTANT Call action on application deploy, like servlet with load-on-startup (Struts 2)

Hi to all, i have the next situation: I need to call an action on application startup like you can call a servlet on application startup by setting parameter servlet on web.xml . I can’t use a servlet because i need to trigger my interceptors that initialize JPA EntityManager . Is there a way to achieve this?

Best regards.