1 | <li>{strip}<a id="languageSwitchLink" title="{'Language'|@translate}" class="pwg-state-default pwg-button" rel="nofollow"> |
---|
2 | <span class="pwg-icon" style="background:url('{$lang_switch.Active.img}') center center no-repeat;"> </span><span class="pwg-button-text">{'Language'|@translate}</span> |
---|
3 | </a> |
---|
4 | <div id="languageSwitchBox" class="switchBox"> |
---|
5 | <div class="switchBoxTitle">{'Language'|@translate}</div> |
---|
6 | {foreach from=$lang_switch.flags item=flag name=f} |
---|
7 | <a rel="nofollow" href="{$flag.url}"><img class="flags" src="{$flag.img}" alt="{$flag.alt}"> {$flag.title}</a> |
---|
8 | {if ($smarty.foreach.f.index+1)%3 == 0}<br>{/if} |
---|
9 | {/foreach} |
---|
10 | </div> |
---|
11 | {/strip}</li> |
---|
12 | |
---|
13 | {footer_script require='jquery'}{literal} |
---|
14 | jQuery("#languageSwitchLink").click(function() { |
---|
15 | var elt = jQuery("#languageSwitchBox"); |
---|
16 | elt.css("left", Math.min(jQuery(this).offset().left, jQuery(window).width() - elt.outerWidth(true) - 5)) |
---|
17 | .css("top", jQuery(this).offset().top + jQuery(this).outerHeight(true)) |
---|
18 | .toggle(); |
---|
19 | }); |
---|
20 | jQuery("#languageSwitchBox").on("mouseleave", function() { |
---|
21 | jQuery(this).hide(); |
---|
22 | }); |
---|
23 | {/literal}{/footer_script} |
---|
24 | |
---|
25 | {* <!-- switchBox structure for theme which don't include default style --> *} |
---|
26 | {if $themeconf.parent != 'default' or (isset($themeconf.load_parent_local_head) and $themeconf.load_parent_local_head == false) } |
---|
27 | {combine_css path=$LANGUAGE_SWITCH_PATH|@cat:"default.css"} |
---|
28 | {/if} |
---|
29 | |
---|
30 | {* <!-- stylish for non core themes (should be removed when all themes are updated) --> *} |
---|
31 | {if $themeconf.name != 'clear' and $themeconf.name != 'dark' and $themeconf.name != 'elegant' and $themeconf.name != 'Sylvia'} |
---|
32 | {combine_css path=$LANGUAGE_SWITCH_PATH|@cat:"style.css"} |
---|
33 | {/if} |
---|
34 | |
---|
35 | {* <!-- common style specific for LanguageSwitch --> *} |
---|
36 | {combine_css path=$LANGUAGE_SWITCH_PATH|@cat:"language_switch.css"} |
---|