aspose file tools*
The moose likes Struts and the fly likes Question about saveTokens Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Question about saveTokens" Watch "Question about saveTokens" New topic
Author

Question about saveTokens

howard franklin
Greenhorn

Joined: Sep 09, 2012
Posts: 20
This page is submitted using button that calls a function that submits the page using the dom.
After it sets a function/parameter


document.forms['I'].elements['function'].value = 'addOffice';
document.forms['I'].submit();


This sends it to the action addOffice.

My question is about the saveToken.

I understand that saveToken() - generate the token key and save to request/session attribute.

My problem is that I am debugging this and I see that it does not get pass the SaveToken(request) statement and then
my page refreshes. Is there something that I am missing here?

I appreciate any help




resetParentStatement(request, frm);
setRequestAttributes (request, frm, null, true);
saveToken (request);

//return mapping.getInputForward ();
ActionForward testActionForward = mapping.getInputForward();
StringBuffer path = new StringBuffer (testActionForward.getPath());
path.append("?#arrest");
ActionForward myNewActionForward = new ActionForward(path.toString());
myNewActionForward.setRedirect (true);
return myNewActionForward;

Howard
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Question about saveTokens
 
Similar Threads
ActionForward and token Help please....
Handling double click on submit
saveToken in a PRG pattern? will it work with Meta refresh for a long action?
Struts Validator Plug-In
saveToken & isTokenValid don't work