<{assign var="weekArr" value="|"|explode:$lang.calendar_s_week|smarty:nodefaults}>
<{foreach name="month" key="month_date" item="month" from=$action.date_list}>
<{assign var="index" value=$smarty.foreach.month.iteration-1}>
<{if ($index % 4 == 0) }>
<{/if}>
<{section name=wday loop=$weekArr}>
<{assign var="index" value=$smarty.section.wday.iteration-1}>
<{if ($index % 7 == 0) }>
<{assign var="day_class" value="calendar_sunday"}>
<{elseif ($index % 7 == 6) }>
<{assign var="day_class" value="calendar_saturday"}>
<{else}>
<{assign var="day_class" value="calendar_weekday"}>
<{/if}>
<{if ($smarty.section.wday.first) }>
<{/if}>
<{$weekArr[wday]}>
|
<{if ($smarty.section.wday.last) }>
<{/if}>
<{/section}>
<{section name=timestamp loop=$month.end_timestamp start=$month.start_timestamp step=86400}>
<{assign var="timestamp" value=$smarty.section.timestamp.index}>
<{assign var="date" value=$smarty.section.timestamp.index|date_format:"%Y%m%d"}>
<{assign var="index" value=$smarty.section.timestamp.iteration-1}>
<{assign var="year_string" value="`$timestamp`"|date_format:$lang.calendar_monthly_year_format|smarty:nodefaults}>
<{assign var="month_string" value="`$timestamp`"|date_format:$lang.calendar_monthly_month_format|smarty:nodefaults}>
<{assign var="day_string" value=$lang.calendar_weekly_format|smarty:nodefaults|date:"`$timestamp`"}>
<{assign var="wday" value="w"|date:"`$timestamp`"}>
<{assign var="wday_string" value=$lang.calendar_wday_format|smarty:nodefaults|sprintf:"`$weekArr.$wday`"}>
<{if (substr($date,0,6) != $month_date) }>
<{assign var="day_class" value="calendar_outside"}>
<{elseif ($action.holidays.$date) }>
<{assign var="day_class" value="calendar_holiday"}>
<{elseif ($index % 7 == 0) }>
<{assign var="day_class" value="calendar_sunday"}>
<{elseif ($index % 7 == 6) }>
<{assign var="day_class" value="calendar_saturday"}>
<{else}>
<{assign var="day_class" value="calendar_weekday"}>
<{/if}>
<{if ($index % 7 == 0) }>
<{/if}>
<{$timestamp|date_format:"%e"}>
|
<{if ($index % 7 == 6) }>
<{/if}>
<{/section}>
|
<{assign var="index" value=$smarty.foreach.month.iteration-1}>
<{if ($index % 4 == 3) }>
<{/if}>
<{/foreach}>