You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by mule_user <sg...@aol.com> on 2009/05/14 22:47:12 UTC

getRequestURI() for Struts 1.1 app in WebSphere 5.1 returns query string if query string is appended in path of forward in struts-config.xml

I have to maintain Struts 1.1 application that will be running in WebSphere
5.1 (J2EE 1.3). 

If struts-config.xml has an entry like: <forward name="success"
path="/submit.do?my=Update"/>   

then request.getRequestURI()  returns the query string          

In other words, if forward has request parameters, then
request.getRequestURI()  in Action class returns
/MyProjWeb/submit.do?my=Update

According to specification, getRequestURI()  should not return query string.
According to specification, getRequestURI()  should return
/MyProjWeb/submit.do only.

However, noticing that Struts 1.1 application deployed in WebSphere 5.1.,
returns query string for getRequestURI().

On the contrary, if the same Struts 1.1 application is tested in WebSphere
6.1; then getRequestURI() call correctly returns /MyProjWeb/submit.do for
the same forward with appended query string. WebSphere 6.1 behaves correctly
according to specification. 

Is anyone familiar with this bevavior for forward with query string in
WebSphere 5.1? 
-- 
View this message in context: http://www.nabble.com/getRequestURI%28%29-for-Struts-1.1-app-in-WebSphere-5.1-returns-query-string-if-query-string-is-appended-in-path-of-forward-in-struts-config.xml-tp23548705p23548705.html
Sent from the Struts - Dev mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: getRequestURI() for Struts 1.1 app in WebSphere 5.1 returns query string if query string is appended in path of forward in struts-config.xml

Posted by Philip Luppens <ph...@gmail.com>.
On Thu, May 14, 2009 at 10:47 PM, mule_user <sg...@aol.com> wrote:
>
> I have to maintain Struts 1.1 application that will be running in WebSphere
> 5.1 (J2EE 1.3).
>
> If struts-config.xml has an entry like: <forward name="success"
> path="/submit.do?my=Update"/>
>
> then request.getRequestURI()  returns the query string
>
> In other words, if forward has request parameters, then
> request.getRequestURI()  in Action class returns
> /MyProjWeb/submit.do?my=Update
>
> According to specification, getRequestURI()  should not return query string.
> According to specification, getRequestURI()  should return
> /MyProjWeb/submit.do only.
>
> However, noticing that Struts 1.1 application deployed in WebSphere 5.1.,
> returns query string for getRequestURI().
>
> On the contrary, if the same Struts 1.1 application is tested in WebSphere
> 6.1; then getRequestURI() call correctly returns /MyProjWeb/submit.do for
> the same forward with appended query string. WebSphere 6.1 behaves correctly
> according to specification.
>
> Is anyone familiar with this bevavior for forward with query string in
> WebSphere 5.1?

Please ask user questions on the Struts user mailing list. The dev
list is for the development of Struts itself.

-- 
"We cannot change the cards we are dealt, just how we play the hand."
- Randy Pausch

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: getRequestURI() for Struts 1.1 app in WebSphere 5.1 returns query string if query string is appended in path of forward in struts-config.xml

Posted by Randy Burgess <rb...@ultiweb.com>.
I've noticed differences in HttpServletRequest method results between
application servers and they don't seem to always stick to the spec.  Is WAS
5.1 on Servlet 2.2 or 2.1 or even older? Make sure you're looking at the
right spec for that version too.


Randy Burgess


> From: mule_user <sg...@aol.com>
> Reply-To: Struts Developers List <de...@struts.apache.org>
> Date: Thu, 14 May 2009 13:47:12 -0700 (PDT)
> To: <de...@struts.apache.org>
> Subject: getRequestURI() for Struts 1.1 app in WebSphere 5.1 returns query
> string if query string is appended in path of forward in struts-config.xml
> 
> 
> I have to maintain Struts 1.1 application that will be running in WebSphere
> 5.1 (J2EE 1.3). 
> 
> If struts-config.xml has an entry like: <forward name="success"
> path="/submit.do?my=Update"/>
> 
> then request.getRequestURI()  returns the query string
> 
> In other words, if forward has request parameters, then
> request.getRequestURI()  in Action class returns
> /MyProjWeb/submit.do?my=Update
> 
> According to specification, getRequestURI()  should not return query string.
> According to specification, getRequestURI()  should return
> /MyProjWeb/submit.do only.
> 
> However, noticing that Struts 1.1 application deployed in WebSphere 5.1.,
> returns query string for getRequestURI().
> 
> On the contrary, if the same Struts 1.1 application is tested in WebSphere
> 6.1; then getRequestURI() call correctly returns /MyProjWeb/submit.do for
> the same forward with appended query string. WebSphere 6.1 behaves correctly
> according to specification.
> 
> Is anyone familiar with this bevavior for forward with query string in
> WebSphere 5.1? 
> -- 
> View this message in context:
> http://www.nabble.com/getRequestURI%28%29-for-Struts-1.1-app-in-WebSphere-5.1-
> returns-query-string-if-query-string-is-appended-in-path-of-forward-in-struts-
> config.xml-tp23548705p23548705.html
> Sent from the Struts - Dev mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org