> As far as I know the only way to render a cancel button inside a form is
> this: > > <s:submit value="%{getText('button.label.cancel')}" > action="cancelFormAction"/> > > This requires > > struts.mapper.action.prefix.enabled = true. > > I can't imagine a middle-high size development which does not use a > single cancel button. > > Shouldn't 'struts.mapper.action.prefix.enabled=true' by default? > > Or, is there any other way to render a cancel button? > > There are several ways. One is to use a action method instead of an action: <s:submit value="%{getText('button.label.cancel')}" method="cancel" /> That requires to enable Dynamic Method Invocation. And your actions must implement a cancel() method. Another option is to use not a button but a simple link. If your application is stateless there is no need to POST a cancel request. Regards, Christoph This Email was scanned by Sophos Anti Virus