Whetu Paitai
Member
Hi there,
I am trying to move the language chooser up to the user bar and have a switch that switches between two languages.
I am using the following html setup:
The CSS is from this tutorial: http://callmenick.com/post/css-toggle-switch-examples
What I think I need it to do is use these lines as stated in this thread: https://xenforo.com/community/threads/language-switch-phrase.11165/
Problem is, I don't know how to properly implement it.
Any ideas?
I am trying to move the language chooser up to the user bar and have a switch that switches between two languages.
I am using the following html setup:
Code:
<div class="switch">
<input id="cmn-toggle-7" class="cmn-toggle cmn-toggle-yes-no" type="checkbox">
<label for="cmn-toggle-7" data-on="Māori" data-off="English"></label>
</div>
The CSS is from this tutorial: http://callmenick.com/post/css-toggle-switch-examples
What I think I need it to do is use these lines as stated in this thread: https://xenforo.com/community/threads/language-switch-phrase.11165/
Code:
<a href="{xen:link 'misc/language', '', 'language_id=1', '_xfToken={$visitor.csrf_token_page}', 'redirect={$redirect}'}"<xen:if is="{$visitor.language_id} == 1"> style="font-weight: bold;"</xen:if>>English</a>
<a href="{xen:link 'misc/language', '', 'language_id=2', '_xfToken={$visitor.csrf_token_page}', 'redirect={$redirect}'}"<xen:if is="{$visitor.language_id} == 2"> style="font-weight: bold;"</xen:if>>Māori</a>
Problem is, I don't know how to properly implement it.
Any ideas?