[OT] Re: Every action is getting called twice
VenuGopalArkala wrote: if ur using and in js ur giving function formSubmit(){ document.populationSetForm.addNewR.value = ''; form.submit(); // this is the problem } Instead of form.submit() give return true; // ur problem will be solved O_o 1) Original poster was using Struts 2 2) Original poster wasn't having an issue with forms 3) Original poster posted a year ago Dave - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
Re: Every action is getting called twice
if ur using and in js ur giving function formSubmit(){ document.populationSetForm.addNewR.value = ''; form.submit(); // this is the problem } Instead of form.submit() give return true; // ur problem will be solved Manish(Java) wrote: > > HI, Charbel > > In your problem, please make sure that your deployed application context > is > loaded only once. Because here,the problem might be related with it. > > Try it first and see what happens. > > Manish > - Original Message - > From: "Charbel Abdul-Massih" > To: > Sent: Tuesday, February 12, 2008 2:53 AM > Subject: Every action is getting called twice > > > What am I doing wrong? Every request to an action goes into the actions' > execute method twice... > > I am sure that I am returning SUCCESS from the action, and is mapped to a > valid JSP. > > Thanks, > Charbel > > > - > To unsubscribe, e-mail: user-unsubscr...@struts.apache.org > For additional commands, e-mail: user-h...@struts.apache.org > > > -- View this message in context: http://www.nabble.com/Every-action-is-getting-called-twice-tp15420991p22288419.html Sent from the Struts - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
Re: Every action is getting called twice
HI, Charbel In your problem, please make sure that your deployed application context is loaded only once. Because here,the problem might be related with it. Try it first and see what happens. Manish - Original Message - From: "Charbel Abdul-Massih" <[EMAIL PROTECTED]> To: Sent: Tuesday, February 12, 2008 2:53 AM Subject: Every action is getting called twice What am I doing wrong? Every request to an action goes into the actions' execute method twice... I am sure that I am returning SUCCESS from the action, and is mapped to a valid JSP. Thanks, Charbel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Every action is getting called twice
Another simple sanity check would be to delete the content of your JSP (not the JSP itself, just make it an empty file). If that solves the problem, you have an tag with an empty 'src' attribute or something similar that's causing the browser to issue another request to the same URL. L. Wes Wannemacher wrote: If you remove your custom interceptor, do you have the same problem? If answer == no, post your interceptor code. There may be something that you're not seeing that multiple eyes can help you with. Else Try putting your interceptor below the ref to paramPrepareParamsStack, I've found it's usually better to put your own interceptors after the s2 interceptors as they perform quite a bit of processing that one might assume has already happened. -Wes On Mon, 2008-02-11 at 16:30 -0500, Charbel Abdul-Massih wrote: Here's a snippet from my struts.xml /jsp/dashboard.jsp When I access dashboard.action, the execute method is called twice... The login interceptor checks for logged in session, and if true, calls Return actionInvocation.invoke(); Does this help any??? -Original Message- From: Dave Newton [mailto:[EMAIL PROTECTED] Sent: Monday, February 11, 2008 4:26 PM To: Struts Users Mailing List Subject: Re: Every action is getting called twice --- Charbel Abdul-Massih <[EMAIL PROTECTED]> wrote: What am I doing wrong? Every request to an action goes into the actions' execute method twice... I am sure that I am returning SUCCESS from the action, and is mapped to a valid JSP. You are not providing enough information for anybody to help you. Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Every action is getting called twice
On 2/11/08, Charbel Abdul-Massih <[EMAIL PROTECTED]> wrote: > What am I doing wrong? Every request to an action goes into the actions' > execute method twice... This is going to sound unrelated, but, do you use Firefox browser with Firebug enabled to test your code. I ran into one weird problem myself where I was seeing double executions when Firebug was enabled. That may not be the problem in your case, but, your symptoms are similar to my situation where this was indeed the culprit. If you normally test with Firebug enabled, disable it and try your test again to see whether that changes things at all. Good Luck, Van -- | Mike "Van" Riper | http://weblogs.java.net/blog/van_riper/ - | Silicon Valley Web Developer JUG | mailto:[EMAIL PROTECTED] | https://sv-web-jug.dev.java.net - | Silicon Valley Google Technology User Group | mailto:[EMAIL PROTECTED] | http://sv-gtug.org - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Every action is getting called twice
If you remove your custom interceptor, do you have the same problem? If answer == no, post your interceptor code. There may be something that you're not seeing that multiple eyes can help you with. Else Try putting your interceptor below the ref to paramPrepareParamsStack, I've found it's usually better to put your own interceptors after the s2 interceptors as they perform quite a bit of processing that one might assume has already happened. -Wes On Mon, 2008-02-11 at 16:30 -0500, Charbel Abdul-Massih wrote: > Here's a snippet from my struts.xml > > > > > > > > > > > > > > > > /jsp/dashboard.jsp > > > When I access dashboard.action, the execute method is called twice... > The login interceptor checks for logged in session, and if true, calls > > Return actionInvocation.invoke(); > > Does this help any??? > > > -Original Message- > From: Dave Newton [mailto:[EMAIL PROTECTED] > Sent: Monday, February 11, 2008 4:26 PM > To: Struts Users Mailing List > Subject: Re: Every action is getting called twice > > --- Charbel Abdul-Massih <[EMAIL PROTECTED]> wrote: > > What am I doing wrong? Every request to an action goes into the actions' > > execute method twice... > > > > I am sure that I am returning SUCCESS from the action, and is mapped to a > > valid JSP. > > You are not providing enough information for anybody to help you. > > Dave > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Every action is getting called twice
Here's a snippet from my struts.xml /jsp/dashboard.jsp When I access dashboard.action, the execute method is called twice... The login interceptor checks for logged in session, and if true, calls Return actionInvocation.invoke(); Does this help any??? -Original Message- From: Dave Newton [mailto:[EMAIL PROTECTED] Sent: Monday, February 11, 2008 4:26 PM To: Struts Users Mailing List Subject: Re: Every action is getting called twice --- Charbel Abdul-Massih <[EMAIL PROTECTED]> wrote: > What am I doing wrong? Every request to an action goes into the actions' > execute method twice... > > I am sure that I am returning SUCCESS from the action, and is mapped to a > valid JSP. You are not providing enough information for anybody to help you. Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Every action is getting called twice
--- Charbel Abdul-Massih <[EMAIL PROTECTED]> wrote: > What am I doing wrong? Every request to an action goes into the actions' > execute method twice... > > I am sure that I am returning SUCCESS from the action, and is mapped to a > valid JSP. You are not providing enough information for anybody to help you. Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Every action is getting called twice
What am I doing wrong? Every request to an action goes into the actions' execute method twice... I am sure that I am returning SUCCESS from the action, and is mapped to a valid JSP. Thanks, Charbel