Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Wiki Markup
{snippet:id=description|javadoc=true|url=com.opensymphony.webwork.dispatcher.ServletRedirectResult}

Parameters

Wiki Markup
{snippet:id=params|javadoc=true|url=com.opensymphony.webwork.dispatcher.ServletRedirectResult}

Examples

Wiki Markup
{snippet:id=example|lang=xml|javadoc=true|url=com.opensymphony.webwork.dispatcher.ServletRedirectResult}

Redirect

The response is told to redirect the browser to the specified location (a new request from the client). The consequence of doing this means that the action (action instance, action errors, field errors, etc) that was just executed is lost and no longer available. This is because actions are built on a single-thread model. The only way to pass data is through the session or with web parameters (url?name=value) which can be OGNL expressions.

Parameters

Required

Description

location

yes

the location to go to after execution

parse

no

true by default. If set to false, the location param will not be parsed for Ognl expressions

Code Block
xmlxml

<result name="success" type="redirect">
    <param name="location">foo.jsp</param>
    <param name="parse">false</param>
</result>