Re: response.addCookie not working inside Struts action class

2007-06-13 Thread nuwan chandrasoma
I also agree with you Dave, +1 Does any one need a guy for a Struts2 project?, i am ready to quit my current job :)) On 6/12/07, Dave Newton [EMAIL PROTECTED] wrote: --- Chris Pratt [EMAIL PROTECTED] wrote: Sorry, for some reason I was stuck on Struts 2. It's 'cuz it's so much better :D

Re: why response.addCookie not working inside Struts action class

2007-06-13 Thread Zoran Avtarovski
Have a look at this: http://www.velocityreviews.com/forums/t124632-struts-set-a-cookie.html Also, in the past or protocol was to use bean:cookie to set cookies, I'm actually sure why, but it works reliably. Z. inside Struts(1.x) Action class, within method public

why response.addCookie not working inside Struts action class

2007-06-12 Thread john lee
inside Struts(1.x) Action class, within method public ActionForward(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception i did the following: ... Cookie me; me=new Cookie(LoginID,xxx); me.setMaxAge(30*24*60*60);

response.addCookie not working inside Struts action class

2007-06-12 Thread john lee
inside Struts(1.x) Action class, within method public ActionForward(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception i did the following: ... Cookie me; me=new Cookie(LoginID,xxx);

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread Chris Pratt
Where'd you get the response? Does your action implement ServletResponseAware? (*Chris*) On 6/12/07, john lee [EMAIL PROTECTED] wrote: inside Struts(1.x) Action class, within method public ActionForward(ActionMapping mapping, ActionForm form, HttpServletRequest request,

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread john lee
i have an login.jsp first, then call action class, if success, then action class forward to different jsp page. my struts-configure.xml will be as the following: action path=/login type=mypackage.LoginAction scope=session forward name=success path=/display.jsp redirect=yes

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread Dave Newton
Huh?! --- Chris Pratt [EMAIL PROTECTED] wrote: Where'd you get the response? Does your action implement ServletResponseAware? On 6/12/07, john lee wrote: inside Struts(1.x) Action class, within method public ActionForward(ActionMapping mapping, ActionForm form,

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread Dave Newton
I'd check two things first: 1) Make sure the action is actually executing (via breakpoint or logging) 2) where specifically are you checking to see if the cookie (physically) exists? d. --- john lee [EMAIL PROTECTED] wrote: inside Struts(1.x) Action class, within method

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread john lee
the action is executing, checked. also check the cookie under c:\document and setting\username\cookie, but not there, john Dave Newton [EMAIL PROTECTED] wrote: I'd check two things first: 1) Make sure the action is actually executing (via breakpoint or logging) 2) where

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread Chris Pratt
Sorry, for some reason I was stuck on Struts 2. In IE's Internet Options, on the Privacy tab, click the Advanced... button and check the Override automatic cookie handling checkbox, then set both cookie types to Prompt. After that, try again and you'll be able to see all the cookies that are

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread Nuwan Chandrasoma
Mailing List user@struts.apache.org Sent: Tuesday, June 12, 2007 4:42 PM Subject: Re: response.addCookie not working inside Struts action class Sorry, for some reason I was stuck on Struts 2. In IE's Internet Options, on the Privacy tab, click the Advanced... button and check the Override automatic

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread Dave Newton
--- john lee [EMAIL PROTECTED] wrote: also check the cookie under c:\document and setting\username\cookie, but not there, Where? My cookies, at least, are stored per-browser, in various places. Check via the browser. Also check browser settings to make sure cookies are allowed for the URL

Re: response.addCookie not working inside Struts action class

2007-06-12 Thread Dave Newton
--- Chris Pratt [EMAIL PROTECTED] wrote: Sorry, for some reason I was stuck on Struts 2. It's 'cuz it's so much better :D I suspect it may have to do with setting the path or domain, but that's just a guess. +1 d.