Re: Struts token doesn't work problem

2005-01-21 Thread Will Stranathan
Just include a hidden element with the token name and value. Like: You'll have to look in the session to get the token value. I *think* the session key this is under is org.apache.struts.action.TOKEN (looking at the javadoc for that). w On Fri, 21 Jan 2005 09:21:44 +0800 Anthony Hong <[EMAI

Re: Struts token doesn't work problem

2005-01-20 Thread Anthony Hong
Actually I use xslt to do as my view. So I couldn't use struts tags at all. Is there any other mechanism that I could use to control double click? I have to simulate struts's token action? -- Anthony Hong - To unsubscribe, e-ma

Re: Struts token doesn't work problem

2005-01-20 Thread Jim Barrows
On Thu, 20 Jan 2005 09:54:00 -0500, Jeff Beal <[EMAIL PROTECTED]> wrote: > Look at the source for the tag and see how it inserts the > token. The token is just a session-scoped attribute and it's inserted > on the page as a hidden form field. You can probably write it to the > page easily withou

Re: Struts token doesn't work problem

2005-01-20 Thread Jeff Beal
Look at the source for the tag and see how it inserts the token. The token is just a session-scoped attribute and it's inserted on the page as a hidden form field. You can probably write it to the page easily without using the tag. -- Jeff Anthony Hong wrote: I think my problem is I didn't

Re: Struts token doesn't work problem

2005-01-20 Thread Anthony Hong
I think my problem is I didn't use html:form struts tag, I use form tag in html directly. So it didn't work. Thanks. -- Anthony Hong - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: Struts token doesn't work problem

2005-01-20 Thread Will Stranathan
You have to do a couple of things: 1) While preparing the form, call generateToken(request); 2) Make sure you use the html:form tag - otherwise the token won't get put on the page. 3) When the user submits, do two things 3a) Check isTokenValid(request) - if it is, contiue, if not, warn the user.

Struts token doesn't work problem

2005-01-20 Thread Anthony Hong
I use server side xslt transformation and return it to client side for rendering. I saw use struts token mechanism can control form double submit problem. But it doesn't work in my enviorment. Is there any additional step I should put it into my response? Or it only work with the JSP view? -- An