I am in the process of redirecting a URL and I wanted to use the 'RewriteRule' directive when in the process of doing so.
I currently have a rule as follows:
RewriteRule ^/application/web/reservation/index.jsp https://application.domain.com/application2/web/reservation/audioForm.zul [R,L]
However I also want this to work if a locale is added to the end of the first URL. It could be various different locales (never static), so I want the RewriteRule to take whatever comes after '.jsp' in the first URL and place it after '.zul' in the second.
For example something like:
RewriteRule ^/application/web/reservation/index.jsp(*)$ https://application.domain.com/application2/web/reservation/audioForm.zul$1 [R,L]
I believe I have the syntax wrong for the replacement portion:
(*)$ and $1 respectively
Just so you can see what the link looks like with the locale, I have placed an example below:
https://application.domain.com/application/web/reservation/index.jsp?locale=de-DE
I would want to place '?locale=de-DE' after .zul in the second URL.
Can anyone tell me what I am doing wrong? Any help would be greatly appreciated.
Best Regards