Orkun Posted April 27, 2022 Share Posted April 27, 2022 Hi Guys I have made this hook here to "deactivate" the default language with a click of a toggle/checkbox. The thing is my hook here works only when I am on that specific page. How can I make it work inside e.g. inside a foreach loop where I output the language switcher (when the user language isn't english)? KR Orkun Link to comment Share on other sites More sharing options...
Orkun Posted April 27, 2022 Author Share Posted April 27, 2022 Nevermind. I solved it by also checking the "language" argument when some is present. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now