i was displaying a list of stores to get the flags.
But i want to display it in my own order so, as far as i know, i makes the loop as normal:
<?php foreach ($_stores as $_store): ?>
<?php
// do not print flag for the current store
if (Mage::app()->getStore()->getStoreId() == $_store->getId()) {
continue;
}
if (!in_array($_store->getId(), array(1, 2, 9, 16, 18, 21, 22, 23))) {
continue;
}
There i check to don`t show the current store, and to check only the stores that i enter manually into the array.
But now i wants to get the stores in my own order.
I show it with this code:
< li>
<a href="<?php echo $url ?>">
<?php
$store_id = $_store->getId();
$logo_src = Mage::getStoreConfig('design/header/logo_src_small', $store_id)
?>
<img class="mini-icon" src="<?php echo Mage::getBaseUrl('skin') ?>frontend/default/DESIGN/<?php echo $logo_src ?>" />
<img class="mini-lang" src="<?php echo $this->getSkinUrl("images/flags/flag_$country.png") ?>" />
<span class="span-lang" title="<?php echo $_store->getTranslatedName() ?>"><?php echo $_store->getTranslatedName() ?></span>
</a>
</li>
EDIT My own order was: 1 - 2 -21 -23 -22 -16 -18
I did it on BE -> store_views -> store_order