Пример #1
0
    default:
        if (empty($eid)) {
            // Default action, view the calendar or event
            COM_setArgNames(array('eid', 'ts', 'range', 'cat'));
            $eid = COM_sanitizeID(COM_getArgument('eid'), false);
        }
        if (!empty($eid)) {
            USES_evlist_class_repeat();
            $Rep = new evRepeat($eid);
            $pagetitle = COM_stripslashes($Rep->Event->title);
            if ($view == 'print') {
                $template = 'event_print';
                $query = '';
            }
            $query = isset($_GET['query']) ? $_GET['query'] : '';
            $content .= $Rep->Detail('', $query, $template);
        } else {
            // Shouldn't be in this file without an event ID to display or edit
            echo COM_refresh(EVLIST_URL . '/index.php');
            exit;
        }
        break;
}
$display = EVLIST_siteHeader($pagetitle);
$display .= EVLIST_calHeader(date('Y'), date('m'), date('d'), 'detail', $cat_id, $cal_id);
if (!empty($msg)) {
    $display .= COM_startBlock($LANG_EVLIST['alert'], '', 'blockheader-message.thtml');
    $display .= $LANG_EVLIST['messages'][$msg];
    $display .= COM_endBlock('blockfooter-message.thtml');
}
$display .= $content;