This function is part of the WMPL-Plugin (Language-Selector) for Wordpress. What I need is a extension (if / else) of this function which makes it possible to show another flag-image on active sites.
function language_selector_flags(){
$languages = icl_get_languages('skip_missing=0&orderby=code');
if(!empty($languages)){
foreach($languages as $l){
if(!$l['active']) echo '<a href="'.$l['url'].'">';
echo '<img src="'.$l['country_flag_url'].'" height="12"
alt="'.$l['language_code'].'" width="18" />';
if(!$l['active']) echo '</a>';
}
}
}
The CSS isn't a problem, but my php-skills are on a very low level. It would be great if anyone can tell me a solution. Thanks for your helping me!