Friday, 6 September 2013

Double Slash in URL

Double Slash in URL

I'm using Struts2, Spring, Hibernate,cetc and my problem is that my url
looks like this:
localhost:8080/sample-1.0//welcome.action
Given to understand that double slashes are for redirection how do I
prevent this double slash from occurring?
I've given in my welcome.jsp page like this :
response.sendRedirect(request.getContextPath()+"//"+"welcome.action");
I've tried removing the double slash there and it reflects in the url, but
I get a blank page with no action taking place neither does it throw
exceptions.
Any idea how to resolve this issue?

No comments:

Post a Comment