Thank you Chouby for so fast and good answer:) You are amazing programmer! You just gave me what i needed, i've search for simpler solution, but this works even better :)
This line of code gave me possibility to add bootstrap classes for button languages: printf('<div class = "%s" ><a href = "%s" >%s</a></div>'
so you understood my problem very well :)
I have just added (array('raw' => 1));
Here is the code if someone will be searching for this solution:
<?php $languages = pll_the_languages(array('raw' => 1));
foreach ($languages as $language){
printf('<div class = "%s"><a href = "%s" class="btn btn-default lang-btn">%s</a></div>',
'lang-' . $language['slug'],
$language['url'],
strtoupper($language['slug']
);
}
?>
Thank You Chouby one more time:) Your plugin is so wonderful!
Best Regards
Morten