Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Bill Siggelkow
NP - by the way, if you do end up wanting to look at a custom ExceptionHandler is really pretty easy -- about as easy as writing an Action! Bill Siggelkow Erik Weber wrote: And thanks for posting in the first place, or I might not have figured this out. Erik Erik Weber wrote: Bill, sorry, I fo

Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Erik Weber
And thanks for posting in the first place, or I might not have figured this out. Erik Erik Weber wrote: Bill, sorry, I found the problem. I was invoking resetToken after making sure the form was valid, but before one of these declaratively-handled exceptions was being thrown, in my "save" acti

Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Erik Weber
Bill, sorry, I found the problem. I was invoking resetToken after making sure the form was valid, but before one of these declaratively-handled exceptions was being thrown, in my "save" action. I put the resetToken invocation right after the isTokenValid invocation, out of habit. But resetToken

Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Erik Weber
Yes, my "input" attribute is set to the JSP I came from. Also I tried with and without the "path" attribute to the exception element itself. No luck. I am using 1.1. I wonder if this is the problem. Where would the token field get "whacked" from? Whose field is it? There is nothing required of

Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Bill Siggelkow
Erik Weber wrote: Bill, my login action is almost identical to yours up until the forward element, but I *am* losing the token. You said you thought this might happen if I redirected back to the login page instead of forwarding, but I don't even know how I would do that . . . What version of St

Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Erik Weber
Bill, my login action is almost identical to yours up until the forward element, but I *am* losing the token. You said you thought this might happen if I redirected back to the login page instead of forwarding, but I don't even know how I would do that . . . What version of Struts are you using

Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Bill Siggelkow
Erik, I just tried an example of what you are saying (triggering a declarative exception and then losing the token in the redisplayed form) and I did not lose the token! Here is the action mapping I am using: type="com.oreilly.strutsckbk.ch09.PasswordMatchException"/>

Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Erik Weber
Susan, I could not use your option, but it did lead me to a solution. I would like to know if anyone has a better solution, since mine involves catching and rethrowing an Exception, which is, however small, a performance hit to take. Also, it kind of defeats the purpose of Struts' declarative E

Re: Problem with saveToken(HttpServletRequest)

2004-08-25 Thread Susan Bradeen
Erik Weber <[EMAIL PROTECTED]> wrote on 08/25/2004 09:03:18 AM: > I am using saveToken, isTokenValid, etc., to ensure that a > registration/update form is not stale. I invoke this method from execute > in the setup Action, just before forwarding to the form page. > > When the form is submitted