So we are currently supporting two web apps and want to stop doing so in the near future. So all urls targeting the old maven project we want to redirect to a static page.
To do so I have:
1- Added the following dependency:
2- Added the following to my web.xml file (after jstl setup and before servlet setup)
And then added a urlrewrite.xml file with the following rule just for testing:
<from>http://localhost/start/of/url/ (the actual start of the url)</from>
I am totally new to this concept/configurations as I am working on a spring project but have to modify this maven web app that is not in spring.
So the redirection is not taking effect and not affecting the flow at all, any idea?
Update: I changed the from tag to /*
that worked, but the page it is redirecting me to is http://www.google.com/http://www.google.com/http://www.google.com/http://www.google.com/ (several times after each other), any ideas?
<urlrewrite> <rule> <from>^(.*)</from> <to type="redirect">http://www.google.com/</to> </rule> </urlrewrite>
Try this, it should work... tested...