1 [%# menu: generate sequence of buttons with optional left/right/select
3 # buttons = [ # list of buttons
4 # { link => 'page1.html', text => 'First Page' },
5 # { link => 'page2.html', text => 'Second Page' },
8 # select # item to select in range 1 to n (0: none)
9 # left # add left arrowhead to first item
10 # right # add right arrowhead to last item
12 [% INCLUDE html/button
15 left = loop.first ? left : 0
16 right = loop.last ? right : 0
17 select = (select == loop.count) ? select : 0