', $context['view_week'] ? template_show_week_grid('main') : template_show_month_grid('main');
template_button_strip($context['calendar_buttons'], 'right');
// Show some controls to allow easy calendar navigation.
echo '
';
}
// Template for posting a calendar event.
function template_event_post()
{
global $context, $settings, $options, $txt, $scripturl, $modSettings;
// Start the javascript for drop down boxes...
echo '
';
}
// Display a monthly calendar grid.
function template_show_month_grid($grid_name)
{
global $context, $settings, $options, $txt, $scripturl, $modSettings, $smcFunc;
if (!isset($context['calendar_grid_' . $grid_name]))
return false;
$calendar_data = &$context['calendar_grid_' . $grid_name];
$colspan = !empty($calendar_data['show_week_links']) ? 8 : 7;
if (empty($calendar_data['disable_title']))
{
echo '