E
dit
W
YSIWYG
A
ttach
P
rintable
r1 - 14 Oct 2005 - 22:58:44 -
TWikiContributor
You are here:
TWiki
>
TWiki Web
>
LanguageSelector
---+!! Language selection dropdown *To be included where a language selection is needed, for instance in the top bar or left bar.* Note: this dropdown is only shown if localization is enabled.%BR% Test: %IF{"context i18n_enabled" then='<span style="color:green; font-weight:bold;">localization is enabled</span>' else='<span style="color:red; font-weight:bold;">localization is not enabled</span>'}% %BR% Usage: <verbatim> %INCLUDE{%TWIKIWEB%.LanguageSelector}% </verbatim> Result: %STARTINCLUDE%%IF{"context i18n_enabled" then='<form name="%INCLUDINGWEB%%INCLUDINGTOPIC%ChangeLanguage" action="%SCRIPTURLPATH{"oops"}%/%BASEWEB%/%BASETOPIC%" method="get"><select name="language" onchange="document.%INCLUDINGWEB%%INCLUDINGTOPIC%ChangeLanguage.submit()">%LANGUAGES{format="<option $marker value=\"$langtag\">$langname</option>" selection="%LANGUAGE%" separator=" "}%</select><input type="hidden" name="template" value="oopslanguagechanged" /><noscript><input class="twikiButton" type="submit" value="%MAKETEXT{"Change language"}%" /></noscript></form>'}%%STOPINCLUDE%
E
dit
|
W
YSIWYG
|
A
ttach
|
P
rintable
|
V
iew topic
|
Backlinks:
We
b
,
A
l
l Webs
|
H
istory
: r1
|
M
ore topic actions
TWiki
Log In
TWiki Web
Webs
Main
TWiki
Copyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki?
Send feedback
Note:
Please contribute updates to this topic on TWiki.org at
TWiki:TWiki.LanguageSelector