1

I need to redirect my https url to lowercase using spring how to do that kindly any one suggest solution ..

I follow the steps on following url, it doesn't work for me.

How can I have case insensitive URLS in Spring MVC with annotated mappings

What I need is: if I type STACKOVERFLOW.COM and enter mean it redirect to stackoverflow.com but the above url steps did not meet what I need.

Community
  • 1
  • 1
venkat
  • 73
  • 2
  • 14

1 Answers1

1

there is already a lot of question related to this I think you could easily find a solution here : https://jira.spring.io/browse/SPR-13286

there is also another question on stackoverflow here : case insensitive mapping for Spring MVC @RequestMapping annotations

To modify dynamic URL's you could transform it when you get it in the code with a .toLowerCase() when you recieve it.

I hope it will help you.

Community
  • 1
  • 1
EmCode
  • 344
  • 1
  • 10
  • thanks .. it works for static urls . but for dynamic urls it does not work. – venkat Jun 01 '16 at 13:22
  • where do you enter your dynamic url ? you get it in your code no ? you could transform it when you get it with a .toLowerCase() when you recieve it – EmCode Jun 01 '16 at 13:32
  • @EmCode He meant if there is anything to do this that framework already provides or some regex or annotation while receiving it in code – iAmLearning Jul 04 '22 at 11:21