{* load lang file *} {config_load file="lang`$smarty.const.PLANG`.txt" section="calendar"}
{section name=numloop loop=$calendar.days} {* see if we should go to the next row *} {if not ($smarty.section.numloop.rownum mod 7)} {if not $smarty.section.numloop.last} {/if} {/if} {if $smarty.section.numloop.last} {* pad the cells not yet created *} {math equation = "n - a % n" n=7 a=$calendar.days|@count assign="cells"} {if $cells ne 7} {section name=pad loop=$cells} {/section} {/if} {/if} {/section}
{if $calendar.showNav} «{/if} {$calendar.timeStamp|date_format:'%b. %Y'} {if $calendar.showNav} »{/if}
{#mon#} {#tue#} {#wed#} {#thu#} {#fri#} {#sat#} {#sun#}
{if $calendar.days[numloop].selected} {$calendar.days[numloop].number} {else} {$calendar.days[numloop].number|default:" "} {/if}