Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.
- Index
- » Chameleon / ChameleonLite
- » Chameleon
- » too many redirects
too many redirects
too many redirects
Hello,
I have set up a rule which seems to be working correctly to redirect UK ip address to a UK version of our website. The only issues I get now is an error saying 'too many redirects'.
I assume this is to do with the rule repeatedly sending the request to redirect. How do I make the rule only redirect once and then stop?
Thanks Karen
Re: too many redirects
Hi Karen,
you've correctly diagnosed the issue
There are several ways you could address this.
1 - set up the rule so that only pages that are NOT in the UK version of the web site can make the redirect rule succeed. One way to do this would be to use the Menu selectors to ensure the rule only applies on certain non-UK pages, OR perhaps on "all menu items except the specific UK ones".
2 - in some cases, it may be appropriate to only redirect users once (per session, or maybe forever). After that, if they want to return to the page they landed on originally, you might want to let them do that.
To set this up, when you do the redirect for the first time, you ALSO set a cookie or session variable. You can do this in the Succeed Action (set session cookie A, or set session variable A, etc).
Then make a new rule and place this rule just BEFORE the one that does the redirect.
In this new rule, detect the session variable or cookie (depending on which one you decided to use), which is found in the Quick Rules tab. Then in the Succeed Action for this rule "Stop Processing".
In this way, if they have already been redirected once, then the next time they go to a page, Chameleon doesn't get to the rule that does the redirect, so it won't do it again until the session expires or cookie is removed. (or on a new browser).
Hope that makes sense
Stephen
- Index
- » Chameleon / ChameleonLite
- » Chameleon
- » too many redirects
Board Info
- Board Stats:
- Total Topics:
- 1689
- Total Polls:
- 6
- Total Posts:
- 5941
- Posts this week:
- 1
- User Info:
- Total Users:
- 7618
- Newest User:
- goure1dhowen
- Members Online:
- 0
- Guests Online:
- 153
- Online:
- There are no members online
Forum Legend:
Topic
New
Locked
Sticky
Active
New/Active
New/Locked
New Sticky
Locked/Active
Active/Sticky
Sticky/Locked
Sticky/Active/Locked