Forum Discussion
JeffRay_129268
Nimbostratus
Nov 22, 2015irule based redirection issue
Dear Members, I have a problem of language redirection loop. As per code mentioned below, Preferred Language is detected (i.e fr (french) in browser and redirected by ltm but this redirection goes in...
KarimBenyelloul
Cirrostratus
Nov 22, 2015Hi JeffRay,
Please keep in mind that everytime your client sends a request the Irule is executed. So if the client sends
GET https://www.mylocalnet.us/fr/pages/default.aspx
Accept-Language FR
He'll be redirected to the same url : https://www.mylocalnet.us/fr/pages/default.aspx . causing the looping
One solution to avoid the looping could be to modify your condition inorder to check if the client isn't already going to /fr/* in which case not redirecting him. something like this
elseif { !([HTTP::path] starts_with "/fr") && [HTTP::header "Accept-Language"] starts_with "fr" )
hope it'll help
Karim
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects