Been trying to have gallery generate an alphabetic list of album links.
I used floridave's smarty modifier for sorting which I call from the code. It sorts it fine but doesn't create the links.
Here is my code:
{g->callback type="albumselect.LoadAlbumData" stripTitles=true truncateTitles="20"
createTextTree=true}
{assign var="data"
value=$block.albumselect.LoadAlbumData.albumSelect.titles|@sort|replace:'--':''|print_r}
<ul id="navMainTalisman">
{foreach from=$data.tree item=node}
{if substr($data.titles[$node.id], 0, 2) != "--"}
<center><a href="http://www.website.com
{$data.links.prefix}{$data.links[$node.id]}" class="navMainTalismanLink">
{$data.titles[$node.id]}</a><br>
{/if}
{/foreach}
The smarty modifier
-------------------
function smarty_modifier_sort($arrData) {
return sort($arrData);
}