Custom language switcher
-
Hi,
I need to make a Custom language switcher. Something like this:
ESP | ENG
I was using WPML and I had a function like this:
if (function_exists( 'icl_get_languages' )) { $languages = icl_get_languages('skip_missing=0&orderby=code'); if(!empty($languages)){ foreach($languages as $l){ if($l['active']) { echo '<span>'.$l['language_code'].'</span>'; } else { echo '<a href="'.$l['url'].'">'; echo $l['language_code']; echo '</a>'; } } } }
Is there any way to do it with WP globus?
Viewing 8 replies - 1 through 8 (of 8 total)
Viewing 8 replies - 1 through 8 (of 8 total)
- The topic ‘Custom language switcher’ is closed to new replies.