This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Struts and the fly likes // (double slash) problem in redirect forward with weblogic Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "// (double slash) problem in redirect forward with weblogic" Watch "// (double slash) problem in redirect forward with weblogic" New topic
Author

// (double slash) problem in redirect forward with weblogic

pascal gehl
Greenhorn

Joined: Jun 17, 2002
Posts: 14
Hi,

I have to port a struts application from tomcat to weblogic. The application works great on tomcat but in weblogic we have a big problem. slashes (/) after the contextPath are duplicated.
Example :
contextPath = cp
<forward path="/myAction.do" redirect="true"/>

The generated redirect to http://server.com/cp/myAction.do in tomcat is transformed to http://server.com/cp//myAction.do in weblogic. And it gives us a problem with a thirdparty caching tool.

Does anybody know how to fix this ?

thanks
[ August 09, 2005: Message edited by: pascal gehl ]
Kerry Wilson
Ranch Hand

Joined: Oct 29, 2003
Posts: 254
I do not know if there is a 'fix' for this or not. If the Weblogic Implementation of J2EE returns a slash instead of the empty string for an empty context path, there probably isn't much you can do about it except go through your code and find the redirects. .NET has this problem also. Every time you need to redirect, you have to test for an application path and see if it has a slash or not. It's pretty stupid. In this case, it seems like that would not be a standard implementation of J2EE if what you say is true.


http://www.goodercode.com
SCJP 1.4
 
 
subject: // (double slash) problem in redirect forward with weblogic
 
Similar Threads
problem with URL of the application but works fine with Localhost:port
Redirect behind proxy
Problem in accessing app through URL(Through IIS) but working fine with localhost
site transfer context path problem
// (double slash) problem in redirect forward with weblogic