Using the named parameter (parameters) that Struts2 places on the OGNL
stack should work for you:
<action name="index" class="com.opensymphony.xwork2.ActionSupport">
<result type="redirect-action">
<param name="actionName">submitXmlLicenseRequest</param>
<param name="licenseRequest">${#parameters.licenseRequest}</param>
</result>
</action>
Brice
On Jun 25, 2009 11:36am, "Kelly.Graus" <kelly.gr...@toltech.net> wrote:
Hello,
I am trying to redirect to an action when the default index page is
navigated to. However, I want to include the post params so they are sent
to the action. Here's what I've got so far:
This is the action that I want to redirect to. If I call it directly, it
works as expected.
class="net.toltech.webapps.activation.SubmitXmlLicenseRequestAction">
#{ 'licenseRequest' : 'xmlLicenseRequest' }
name="error">/WEB-INF/jsp/submitXmlLicenseRequest-error.jsp
submitLicenseRequest
This is the redirect action. it redirects to the action, but the post
parameter isn't set.
type="redirect-action">submitXmlLicenseRequest
Here are a few different ways I've tried to get it to work. All of these
end up giving me a Premature end of file Fatal Error.
type="redirect-action">submitXmlLicenseRequest?licenseRequest=${licenseRequest}
type="redirect-action">submitXmlLicenseRequest?licenseRequest=${Parameters.licenseRequest}
submitXmlLicenseRequest
${licenseRequest}
submitXmlLicenseRequest
${Parameters.licenseRequest}
Thanks for any suggestions!
Kelly
--
View this message in context:
http://www.nabble.com/Struts2-redirect-action-with-post-params-tp24207810p24207810.html
Sent from the Struts - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org