Browse albums method

amrock82

Joined: 2008-04-30
Posts: 40
Posted: Wed, 2008-07-16 13:22

Hi all,

Im trying to simply customize the Additemfrombrowser template.

I would like to add a dropdownlist with all the albums and sub-albums ? how can i do ?

Quote:
<select name="{g->formVar var="form[linkedAlbumId]"}">
{foreach from=$ItemAddFromBrowser.albumTree item=album}
<option value="{$album.data.id}"{if $album.data.id == $form.linkedAlbumId}
selected="selected"{/if}>
{"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"|repeat:$album.depth}--
{$album.data.title|default:$album.data.pathComponent}
</option>
{/foreach}

</select>

I guess I have to change this: form[linkedAlbumId]

Is this the only modification I have to do ? Is there anything else ?

Thanks a lot