當前位置: 首頁>>代碼示例>>PHP>>正文


PHP CCalendar::GetFromToHtml方法代碼示例

本文整理匯總了PHP中CCalendar::GetFromToHtml方法的典型用法代碼示例。如果您正苦於以下問題:PHP CCalendar::GetFromToHtml方法的具體用法?PHP CCalendar::GetFromToHtml怎麽用?PHP CCalendar::GetFromToHtml使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在CCalendar的用法示例。


在下文中一共展示了CCalendar::GetFromToHtml方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: GetMessage

?>
</a></td>
			</tr>
			<tr>
				<td class="feed-calendar-view-text-cell-l"><?php 
echo GetMessage('ECLFV_EVENT_START');
?>
:</td>
				<td class="feed-calendar-view-text-cell-r"><span id="feed-event-view-from-<?php 
echo $id;
?>
"></span>
				<?php 
if ($event['DT_SKIP_TIME'] != 'Y' && (intVal($event['~USER_OFFSET_FROM']) != 0 || intVal($event['~USER_OFFSET_TO']) != 0 || $event['TZ_FROM'] != $event['TZ_TO'])) {
    if ($event['TZ_FROM'] == $event['TZ_TO']) {
        $timezoneHint = CCalendar::GetFromToHtml(CCalendar::Timestamp($event['DATE_FROM']), CCalendar::Timestamp($event['DATE_TO']), $event['DT_SKIP_TIME'] == 'Y', $event['DT_LENGTH']);
        $timezoneHint .= ' (' . $event['TZ_FROM'] . ')';
    } else {
        $timezoneHint = GetMessage('EC_VIEW_DATE_FROM_TO', array('#DATE_FROM#' => $event['DATE_FROM'] . ' (' . $event['TZ_FROM'] . ')', '#DATE_TO#' => $event['DATE_TO'] . ' (' . $event['TZ_TO'] . ')'));
    }
    ?>
					<span id="feed-event-tz-hint-<?php 
    echo $id;
    ?>
" data-bx-hint="<?php 
    echo $timezoneHint;
    ?>
" class="bx-cal-view-timezon-icon feed-event-view-timezon-icon"></span>
				<?php 
}
?>
開發者ID:webgksupport,項目名稱:alpina,代碼行數:31,代碼來源:template.php

示例2: GetMessage

<?/* ####### TAB 0 : BASIC ####### */?>
<div id="<?=$id?>view-tab-0-cont" class="bxec-d-cont-div" style="display: block;">
	<div class="bx-cal-view-icon">
		<div class="bx-cal-view-icon-day"><?= $event['FROM_WEEK_DAY']?></div>
		<div class="bx-cal-view-icon-date"><?= $event['FROM_MONTH_DAY']?></div>
	</div>
	<div class="bx-cal-view-text">
		<table>
			<tr>
				<td class="bx-cal-view-text-cell-l"><?= GetMessage('EC_T_NAME')?>:</td>
				<td class="bx-cal-view-text-cell-r"><span class="bx-cal-view-name"><?= htmlspecialcharsEx($event['NAME'])?></span></td>
			</tr>
			<tr>
				<td class="bx-cal-view-text-cell-l"><?= GetMessage('EC_DATE')?>:</td>
				<td class="bx-cal-view-text-cell-r bx-cal-view-from-to">
					<?= CCalendar::GetFromToHtml($event['DT_FROM_TS'], $event['DT_TO_TS'], $event['DT_SKIP_TIME'] == 'Y', $event['DT_LENGTH']);?>
				</td>
			</tr>
			<?
			if ($event['RRULE']):?>
				<?
				$event['RRULE'] = CCalendarEvent::ParseRRULE($event['RRULE']);
				switch ($event['RRULE']['FREQ'])
				{
					case 'DAILY':
						if ($event['RRULE']['INTERVAL'] == 1)
							$repeatHTML = GetMessage('EC_RRULE_EVERY_DAY');
						else
							$repeatHTML = GetMessage('EC_RRULE_EVERY_DAY_1', array('#DAY#' => $event['RRULE']['INTERVAL']));
						break;
					case 'WEEKLY':
開發者ID:rasuldev,項目名稱:torino,代碼行數:31,代碼來源:calendar_sceleton.php

示例3: elseif

$arEvents = CCalendar::GetNearestEventsList(array('bCurUserList' => $arParams['B_CUR_USER_LIST'], 'fromLimit' => $fromLimit, 'toLimit' => $toLimit, 'type' => $arParams['CALENDAR_TYPE'], 'sectionId' => $arParams['CALENDAR_SECTION_ID']));
if ($arEvents == 'access_denied') {
    $arResult['ACCESS_DENIED'] = true;
} elseif ($arEvents == 'inactive_feature') {
    $arResult['INACTIVE_FEATURE'] = true;
} elseif (is_array($arEvents)) {
    if (strpos($arParams['DETAIL_URL'], '?') !== FALSE) {
        $arParams['DETAIL_URL'] = substr($arParams['DETAIL_URL'], 0, strpos($arParams['DETAIL_URL'], '?'));
    }
    $arParams['DETAIL_URL'] = str_replace('#user_id#', $curUserId, strtolower($arParams['DETAIL_URL']));
    for ($i = 0, $l = count($arEvents); $i < $l; $i++) {
        $arEvents[$i]['_DETAIL_URL'] = $arParams['DETAIL_URL'] . '?EVENT_ID=' . $arEvents[$i]['ID'] . '&EVENT_DATE=' . $arEvents[$i]['DT_FROM'];
        if ($arEvents[$i]['IS_MEETING'] && $arEvents[$i]['USER_MEETING']['STATUS'] == 'Q') {
            $arEvents[$i]['_ADD_CLASS'] = ' calendar-not-confirmed';
            $arEvents[$i]['_Q_ICON'] = '<span class="calendar-reminder" title="' . GetMessage('EC_NOT_CONFIRMED') . '">[?]</span>';
        } else {
            $arEvents[$i]['_ADD_CLASS'] = '';
            $arEvents[$i]['_Q_ICON'] = '';
        }
        if ($arEvents[$i]['IMPORTANCE'] == 'high') {
            $arEvents[$i]['_ADD_CLASS'] = ' imortant-event';
        }
        $arEvents[$i]['~FROM_TO_HTML'] = CCalendar::GetFromToHtml($arEvents[$i]['DT_FROM_TS'], $arEvents[$i]['DT_TO_TS'], $arEvents[$i]['DT_SKIP_TIME'] == 'Y', $arEvents[$i]['DT_LENGTH']);
        $arResult['ITEMS'][] = $arEvents[$i];
    }
    array_splice($arResult['ITEMS'], intVal($arParams['EVENTS_COUNT']));
}
if ($arParams['RETURN_ARRAY'] == 'Y') {
    return $arResult;
}
$this->IncludeComponentTemplate();
開發者ID:Satariall,項目名稱:izurit,代碼行數:31,代碼來源:component.php

示例4: DialogViewEvent


//.........這裏部分代碼省略.........
<div id="<?php 
        echo $id;
        ?>
view-tab-0-cont" class="bxec-d-cont-div" style="display: block;">
	<div class="bx-cal-view-icon">
		<div class="bx-cal-view-icon-day"><?php 
        echo $event['FROM_WEEK_DAY'];
        ?>
</div>
		<div class="bx-cal-view-icon-date"><?php 
        echo $event['FROM_MONTH_DAY'];
        ?>
</div>
	</div>
	<div class="bx-cal-view-text">
		<table>
			<tr>
				<td class="bx-cal-view-text-cell-l"><?php 
        echo GetMessage('EC_T_NAME');
        ?>
:</td>
				<td class="bx-cal-view-text-cell-r"><span class="bx-cal-view-name"><?php 
        echo htmlspecialcharsEx($event['NAME']);
        ?>
</span></td>
			</tr>
			<tr>
				<td class="bx-cal-view-text-cell-l"><?php 
        echo GetMessage('EC_DATE');
        ?>
:</td>
				<td class="bx-cal-view-text-cell-r bx-cal-view-from-to">
					<?php 
        echo CCalendar::GetFromToHtml($event['DT_FROM_TS'], $event['DT_TO_TS'], $event['DT_SKIP_TIME'] == 'Y', $event['DT_LENGTH']);
        ?>
				</td>
			</tr>
			<?php 
        if ($event['RRULE']) {
            ?>
				<?php 
            $event['RRULE'] = CCalendarEvent::ParseRRULE($event['RRULE']);
            switch ($event['RRULE']['FREQ']) {
                case 'DAILY':
                    if ($event['RRULE']['INTERVAL'] == 1) {
                        $repeatHTML = GetMessage('EC_RRULE_EVERY_DAY');
                    } else {
                        $repeatHTML = GetMessage('EC_RRULE_EVERY_DAY_1', array('#DAY#' => $event['RRULE']['INTERVAL']));
                    }
                    break;
                case 'WEEKLY':
                    $daysList = array();
                    foreach ($event['RRULE']['BYDAY'] as $day) {
                        $daysList[] = GetMessage('EC_' . $day);
                    }
                    $daysList = implode(', ', $daysList);
                    if ($event['RRULE']['INTERVAL'] == 1) {
                        $repeatHTML = GetMessage('EC_RRULE_EVERY_WEEK', array('#DAYS_LIST#' => $daysList));
                    } else {
                        $repeatHTML = GetMessage('EC_RRULE_EVERY_WEEK_1', array('#WEEK#' => $event['RRULE']['INTERVAL'], '#DAYS_LIST#' => $daysList));
                    }
                    break;
                case 'MONTHLY':
                    if ($event['RRULE']['INTERVAL'] == 1) {
                        $repeatHTML = GetMessage('EC_RRULE_EVERY_MONTH');
                    } else {
開發者ID:Satariall,項目名稱:izurit,代碼行數:67,代碼來源:calendar_sceleton.php


注:本文中的CCalendar::GetFromToHtml方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。