You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Paul Benedict (JIRA)" <ji...@apache.org> on 2007/07/05 03:57:26 UTC
[jira] Closed: (STR-2119) Return appropriate status code when form
validation fails
[ https://issues.apache.org/struts/browse/STR-2119?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Paul Benedict closed STR-2119.
------------------------------
Resolution: Not A Problem
Eric, you can handle this situation today in Struts. Set your Controller's attribute inputForward="true" which will then use your action mapping's input attribute as a forward name. Then foward yourself to an action which can return the HTTP status code you want.
Example:
<controller inputForward="true" />
<action .... input="myInputForward">
<forward name="myInputForward" path="/my400Action" />
</action>
Because you can do this today, I am marking this issue as Not A Problem. There is no enhancement to add or defect to fix.
> Return appropriate status code when form validation fails
> ---------------------------------------------------------
>
> Key: STR-2119
> URL: https://issues.apache.org/struts/browse/STR-2119
> Project: Struts 1
> Issue Type: Improvement
> Components: Core
> Affects Versions: 1.1 Final
> Environment: Operating System: other
> Platform: Other
> Reporter: Eric Jain
> Assignee: Paul Benedict
> Priority: Minor
>
> When redisplaying a form after validation has indicated a failure, a status code
> such as "400 Bad Request" should be used in place of "200 OK". This simplifies
> testing, and is important for applications that need to interact with the web
> interface of an application directly.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.