当前位置: 首页>>代码示例>>PHP>>正文


PHP CModule::includeModule方法代码示例

本文整理汇总了PHP中CModule::includeModule方法的典型用法代码示例。如果您正苦于以下问题:PHP CModule::includeModule方法的具体用法?PHP CModule::includeModule怎么用?PHP CModule::includeModule使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CModule的用法示例。


在下文中一共展示了CModule::includeModule方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __construct

 public function __construct()
 {
     $diskEnabled = \Bitrix\Main\Config\Option::get('disk', 'successfully_converted', false) && CModule::includeModule('disk');
     if (!$diskEnabled) {
         $this->validUrls = array_merge($this->validUrls, array("/company/personal.php", "/extranet/contacts/personal.php", "/docs/index.php", "/docs/shared/index.php", "/workgroups/index.php"));
     }
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:7,代码来源:mobile_event.php

示例2: installDB

 function installDB()
 {
     global $DB, $APPLICATION;
     $this->errors = false;
     if (!$DB->query("SELECT 'x' FROM b_abtest", true)) {
         $createTestTemplates = true;
         $this->errors = $DB->runSQLBatch($_SERVER['DOCUMENT_ROOT'] . '/bitrix/modules/abtest/install/db/' . strtolower($DB->type) . '/install.sql');
     }
     if ($this->errors !== false) {
         $APPLICATION->throwException(implode('', $this->errors));
         return false;
     }
     $eventManager = Bitrix\Main\EventManager::getInstance();
     $eventManager->registerEventHandler('main', 'OnGetCurrentSiteTemplate', 'abtest', '\\Bitrix\\ABTest\\EventHandler', 'onGetCurrentSiteTemplate');
     $eventManager->registerEventHandler('main', 'OnFileRewrite', 'abtest', '\\Bitrix\\ABTest\\EventHandler', 'onFileRewrite');
     $eventManager->registerEventHandlerCompatible('main', 'OnPageStart', 'abtest', '\\Bitrix\\ABTest\\EventHandler', 'onPageStart');
     $eventManager->registerEventHandlerCompatible('main', 'OnPanelCreate', 'abtest', '\\Bitrix\\ABTest\\EventHandler', 'onPanelCreate');
     $eventManager->registerEventHandlerCompatible('conversion', 'OnGetAttributeTypes', 'abtest', '\\Bitrix\\ABTest\\EventHandler', 'onGetAttributeTypes');
     $eventManager->registerEventHandlerCompatible('conversion', 'OnSetDayContextAttributes', 'abtest', '\\Bitrix\\ABTest\\EventHandler', 'onConversionSetContextAttributes');
     registerModule($this->MODULE_ID);
     $defSite = Bitrix\Main\SiteTable::getList(array('order' => array('ACTIVE' => 'DESC', 'DEF' => 'DESC', 'SORT' => 'ASC'), 'select' => array('LID')))->fetch();
     if (!empty($createTestTemplates) && CModule::includeModule('abtest') && !empty($defSite)) {
         $arTestTemplates = array(100 => array('ENABLED' => 'T', 'NAME' => getMessage('ABTEST_SAMPLE1_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE1_DESCR'), 'TEST_DATA' => array('id' => 'sample1', 'list' => array(array('type' => 'template', 'old_value' => '', 'new_value' => '')))), 200 => array('ENABLED' => 'T', 'NAME' => getMessage('ABTEST_SAMPLE2_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE2_DESCR'), 'TEST_DATA' => array('id' => 'sample2', 'list' => array(array('type' => 'page', 'old_value' => '', 'new_value' => '')))), 300 => array('ENABLED' => 'T', 'NAME' => getMessage('ABTEST_SAMPLE3_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE3_DESCR'), 'TEST_DATA' => array('id' => 'sample3', 'list' => array(array('type' => 'page', 'old_value' => '', 'new_value' => '')))), 400 => array('ENABLED' => 'T', 'NAME' => getMessage('ABTEST_SAMPLE4_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE4_DESCR'), 'TEST_DATA' => array('id' => 'sample4', 'list' => array(array('type' => 'page', 'old_value' => '', 'new_value' => '')))), 500 => array('ENABLED' => 'T', 'NAME' => getMessage('ABTEST_SAMPLE5_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE5_DESCR'), 'TEST_DATA' => array('id' => 'sample5', 'list' => array(array('type' => 'page', 'old_value' => '', 'new_value' => '')))), 600 => array('ENABLED' => 'T', 'NAME' => getMessage('ABTEST_SAMPLE6_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE6_DESCR'), 'TEST_DATA' => array('id' => 'sample6', 'list' => array(array('type' => 'page', 'old_value' => '', 'new_value' => '')))), 700 => array('ENABLED' => 'N', 'NAME' => getMessage('ABTEST_SAMPLE7_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE7_DESCR'), 'TEST_DATA' => array('id' => 'sample7', 'list' => array(array('type' => 'composite', 'old_value' => 'N', 'new_value' => 'Y')))), 800 => array('ENABLED' => 'N', 'NAME' => getMessage('ABTEST_SAMPLE8_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE8_DESCR'), 'TEST_DATA' => array('id' => 'sample8', 'list' => array(array('type' => 'cdn', 'old_value' => 'N', 'new_value' => 'Y')))), 900 => array('ENABLED' => 'N', 'NAME' => getMessage('ABTEST_SAMPLE9_NAME'), 'DESCR' => getMessage('ABTEST_SAMPLE9_DESCR'), 'TEST_DATA' => array('id' => 'sample9', 'list' => array(array('type' => 'bigdata', 'old_value' => 'N', 'new_value' => 'Y')))));
         foreach ($arTestTemplates as $sort => $test) {
             $test['SITE_ID'] = $defSite['LID'];
             $test['ACTIVE'] = 'N';
             $test['DURATION'] = 0;
             $test['PORTION'] = 30;
             $test['SORT'] = $sort;
             Bitrix\ABTest\ABTestTable::add($test);
         }
     }
     return true;
 }
开发者ID:Hawkart,项目名称:megatv,代码行数:34,代码来源:index.php

示例3: toEdit

 /**
  * @return array
  */
 protected function toEdit()
 {
     /** @global CUser $USER */
     global $USER;
     if (!$USER->IsAuthorized()) {
         return array('status' => 'error', 'error' => 'auth_error');
     }
     if (!check_bitrix_sessid()) {
         return array('status' => 'error', 'error' => 'sessid_check_failed');
     }
     if ($this->request['action'] !== 'otp_check_activate') {
         return array('status' => 'error', 'error' => 'unknown_action');
     }
     if (!CModule::includeModule('security')) {
         return array('status' => 'error', 'error' => 'security_not_installed');
     }
     try {
         $otp = Otp::getByUser($USER->getid());
         $binarySecret = pack('H*', $this->request->getPost('secret'));
         $otp->regenerate($binarySecret)->syncParameters($this->request->getPost('sync1'), $this->request->getPost('sync2'))->save();
         return array('status' => 'ok');
     } catch (\Bitrix\Security\Mfa\OtpException $e) {
         return array('status' => 'error', 'error' => $e->getMessage());
     }
 }
开发者ID:ASDAFF,项目名称:entask.ru,代码行数:28,代码来源:class.php

示例4: toView

 /**
  * @return array
  */
 protected function toView()
 {
     /* @global CUser $USER */
     global $USER;
     if (!CModule::includeModule('security')) {
         return array('MESSAGE' => Loc::getMessage('SECURITY_AUTH_OTP_MANDATORY_MODULE_ERROR'));
     }
     if (!Otp::isOtpRequiredByMandatory()) {
         return array('MESSAGE' => Loc::getMessage('SECURITY_AUTH_OTP_MANDATORY_NOT_REQUIRED'));
     }
     if ($USER->IsAuthorized()) {
         return array('MESSAGE' => Loc::getMessage('SECURITY_AUTH_OTP_MANDATORY_AUTH_ERROR'));
     }
     $deferredParams = Otp::getDeferredParams();
     if (!$deferredParams['USER_ID']) {
         return array('MESSAGE' => Loc::getMessage('SECURITY_AUTH_OTP_MANDATORY_UNKNOWN_ERROR'));
     }
     $result = array();
     $otp = Otp::getByUser($deferredParams['USER_ID']);
     $otp->regenerate();
     $result['SECRET'] = $otp->getHexSecret();
     $result['TYPE'] = $otp->getType();
     $result['APP_SECRET'] = $otp->getAppSecret();
     $result['APP_SECRET_SPACED'] = chunk_split($result['APP_SECRET'], 4, ' ');
     $result['PROVISION_URI'] = $otp->getProvisioningUri();
     $result['SUCCESSFUL_URL'] = $this->arParams['SUCCESSFUL_URL'];
     $result['TWO_CODE_REQUIRED'] = $otp->getAlgorithm()->isTwoCodeRequired();
     $result['OTP'] = $otp;
     return $result;
 }
开发者ID:rasuldev,项目名称:torino,代码行数:33,代码来源:class.php

示例5: InitFileStorage

 public static function InitFileStorage()
 {
     static $bInited = false;
     $arResult = array();
     if (!$bInited) {
         $bDiskEnabled = \Bitrix\Main\Config\Option::get('disk', 'successfully_converted', false) && CModule::includeModule('disk');
         if ($bDiskEnabled) {
             $storage = \Bitrix\Disk\Driver::getInstance()->getStorageByUserId($GLOBALS["USER"]->GetID());
             if (!$storage) {
                 $arResult = array("ERROR_CODE" => "NO_DISC_STORAGE", "ERROR_MESSAGE" => "No disk storage");
             } else {
                 $folder = $storage->getFolderForUploadedFiles($GLOBALS["USER"]->GetID());
                 if (!$folder) {
                     $arResult = array("ERROR_CODE" => "NO_DISC_FOLDER", "ERROR_MESSAGE" => "No disk folder");
                 } else {
                     $arResult = array("DISC_STORAGE" => $storage, "DISC_FOLDER" => $folder);
                 }
             }
         } elseif (CModule::IncludeModule("webdav")) {
             $data = CWebDavIblock::getRootSectionDataForUser($GLOBALS["USER"]->GetID());
             if (is_array($data)) {
                 $ob = new CWebDavIblock($data["IBLOCK_ID"], "", array("ROOT_SECTION_ID" => $data["SECTION_ID"], "DOCUMENT_TYPE" => array("webdav", 'CIBlockDocumentWebdavSocnet', 'iblock_' . $data['SECTION_ID'] . '_user_' . intval($GLOBALS["USER"]->GetID()))));
             }
             if (!$ob) {
                 $arResult = array("ERROR_CODE" => "NO_WEBDAV_SECTION", "ERROR_MESSAGE" => "No webdav section");
             } else {
                 $arResult = array("WEBDAV_DATA" => $data, "WEBDAV_IBLOCK_OBJECT" => $ob);
             }
         }
         $bInited = true;
     }
     return $arResult;
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:33,代码来源:mobile_helper.php

示例6: AddBlogPost

 public static function AddBlogPost($arFields)
 {
     if (!is_array($_POST)) {
         $_POST = array();
     }
     $_POST = array_merge($_POST, array("apply" => "Y", "decode" => "N"), $arFields);
     $strPathToPost = COption::GetOptionString("socialnetwork", "userblogpost_page", false, SITE_ID);
     $strPathToSmile = COption::GetOptionString("socialnetwork", "smile_page", false, SITE_ID);
     $BlogGroupID = COption::GetOptionString("socialnetwork", "userbloggroup_id", false, SITE_ID);
     $arBlogComponentParams = array("IS_REST" => "Y", "ID" => "new", "PATH_TO_POST" => $strPathToPost, "PATH_TO_SMILE" => $strPathToSmile, "GROUP_ID" => $BlogGroupID, "USER_ID" => $GLOBALS["USER"]->GetID(), "USE_SOCNET" => "Y", "MICROBLOG" => "Y");
     ob_start();
     $result = $GLOBALS["APPLICATION"]->IncludeComponent("bitrix:socialnetwork.blog.post.edit", "", $arBlogComponentParams, false, array("HIDE_ICONS" => "Y"));
     ob_end_clean();
     if (!$result) {
         throw new Exception('Error');
     } else {
         if (isset($arFields["FILES"]) && \Bitrix\Main\Config\Option::get('disk', 'successfully_converted', false) && CModule::includeModule('disk') && ($storage = \Bitrix\Disk\Driver::getInstance()->getStorageByUserId($GLOBALS["USER"]->GetID())) && ($folder = $storage->getFolderForUploadedFiles($GLOBALS["USER"]->GetID()))) {
             // upload to storage
             $arResultFile = array();
             foreach ($arFields["FILES"] as $tmp) {
                 $arFile = CRestUtil::saveFile($tmp);
                 if (is_array($arFile)) {
                     $file = $folder->uploadFile($arFile, array('NAME' => $arFile["name"], 'CREATED_BY' => $GLOBALS["USER"]->GetID()), array(), true);
                     if ($file) {
                         $arResultFile[] = \Bitrix\Disk\Uf\FileUserType::NEW_FILE_PREFIX . $file->getId();
                     }
                 }
             }
             if (!empty($arResultFile)) {
                 CBlogPost::Update($result, array("HAS_PROPS" => "Y", "UF_BLOG_POST_FILE" => $arResultFile));
             }
         }
         return $result;
     }
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:35,代码来源:rest.php

示例7: needProxyToDiskByDocType

 private static function needProxyToDiskByDocType($documentType)
 {
     if (!(\Bitrix\Main\Config\Option::get('disk', 'successfully_converted', false) && CModule::includeModule('disk'))) {
         return false;
     }
     if (empty($documentType)) {
         return false;
     }
     $storage = null;
     if (substr($documentType, 0, 7) == 'STORAGE') {
         $storageId = (int) substr($documentType, 8);
         if ($storageId) {
             $storage = \Bitrix\Disk\Storage::loadById($storageId);
         }
         if ($storage) {
             return $storage;
         }
     }
     list(, $iblockId, $typeLib, $entityId) = explode('_', $documentType);
     if ($typeLib == 'user') {
         $storage = \Bitrix\Disk\Driver::getInstance()->getStorageByUserId($entityId);
     } elseif ($typeLib == 'group') {
         $storage = \Bitrix\Disk\Driver::getInstance()->getStorageByGroupId($entityId);
     } else {
         return false;
     }
     return $storage;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:28,代码来源:iblocksocnetbizproc.php

示例8: __wd_get_root_section

 function __wd_get_root_section($IBLOCK_ID, $object, $object_id)
 {
     $result = CIBlockWebdavSocnet::GetSectionID($IBLOCK_ID, $object, $object_id);
     if (intval($result) > 0) {
         return $result;
     } else {
         __wd_check_uf_use_bp_property($arParams["IBLOCK_ID"]);
         $arFields = array("IBLOCK_ID" => $IBLOCK_ID, "ACTIVE" => "Y", "SOCNET_GROUP_ID" => false, "IBLOCK_SECTION_ID" => 0, "UF_USE_BP" => "N");
         if ($object == "user") {
             $dbUser = CUser::GetByID($object_id);
             $arUser = $dbUser->Fetch();
             $arFields["NAME"] = trim($arUser['LAST_NAME'] . " " . $arUser['FIRST_NAME']);
             $arFields["NAME"] = trim(!empty($arFields["NAME"]) ? $arFields["NAME"] : $arUser['LOGIN']);
             $arFields['CREATED_BY'] = $arUser['ID'];
             $arFields['MODIFIED_BY'] = $arUser['ID'];
             if (CIBlock::GetArrayByID($IBLOCK_ID, "RIGHTS_MODE") === "E") {
                 $arTasks = CWebDavIblock::GetTasks();
                 $arFields['RIGHTS'] = array('n0' => array('GROUP_CODE' => 'U' . $object_id, 'TASK_ID' => $arTasks['X']));
             }
         } else {
             /*		$res = CSocNetGroup::GetByID($arResult["VARIABLES"]["group_id"]);
             				if (!$res)
             				{
             					$arParams["ERROR_MESSAGE"] = GetMessage("SONET_GROUP_NOT_EXISTS");
             					return 0;
             				} */
             $arFields["SOCNET_GROUP_ID"] = $object_id;
             //$arGroup = CSocNetGroup::GetByID($object_id);
             $arFields["NAME"] = GetMessage("SONET_GROUP_PREFIX") . $object_id;
             $dbGroup = CSocNetGroup::GetList(array(), array("ID" => (int) $object_id), false, false, array("ID", "SITE_ID", "NAME"));
             if ($arGroup = $dbGroup->Fetch()) {
                 $arFields["NAME"] = GetMessage("SONET_GROUP_PREFIX") . $arGroup["NAME"];
             }
             if (CIBlock::GetArrayByID($IBLOCK_ID, "RIGHTS_MODE") === "E") {
                 $arTasks = CWebDavIblock::GetTasks();
                 $arFields['RIGHTS'] = array('n0' => array('GROUP_CODE' => 'SG' . $arFields["SOCNET_GROUP_ID"] . '_A', 'TASK_ID' => $arTasks['X']), 'n1' => array('GROUP_CODE' => 'SG' . $arFields["SOCNET_GROUP_ID"] . '_E', 'TASK_ID' => $arTasks['W']), 'n2' => array('GROUP_CODE' => 'SG' . $arFields["SOCNET_GROUP_ID"] . '_K', 'TASK_ID' => $arTasks['W']));
             }
         }
         if (\Bitrix\Main\Config\Option::get('disk', 'successfully_converted', false) && CModule::includeModule('disk')) {
             \Bitrix\Disk\Driver::getInstance()->addGroupStorage($arFields["SOCNET_GROUP_ID"]);
         }
         $GLOBALS["UF_USE_BP"] = $arFields["UF_USE_BP"];
         $GLOBALS["USER_FIELD_MANAGER"]->EditFormAddFields("IBLOCK_" . $IBLOCK_ID . "_SECTION", $arFields);
         $bs = new CIBlockSection();
         $sectionID = $bs->Add($arFields);
         if (!$sectionID) {
             $arParams["ERROR_MESSAGE"] = $bs->LAST_ERROR;
             return 0;
         }
         WDClearComponentCache(array("webdav.element.edit", "webdav.element.hist", "webdav.element.upload", "webdav.element.view", "webdav.menu", "webdav.section.edit", "webdav.section.list"));
         return true;
         /*
         	if ($ob->workflow == 'bizproc')
         	{
         		__wd_create_default_bp_user_and_groups($arBizProcParameters);
         	}
         */
     }
 }
开发者ID:webgksupport,项目名称:alpina,代码行数:59,代码来源:webdav_settings.php

示例9: checkRequired

 protected function checkRequired()
 {
     if (!CModule::includeModule('iblock')) {
         throw new Exception('Bad include iblock');
     }
     if (!CModule::includeModule('webdav')) {
         throw new Exception('Bad include webdav');
     }
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:9,代码来源:webdav_convertor.php

示例10: update

 /**
  * Create new comment for task
  * 
  * @param integer $taskId
  * @param integet $commentId
  * @param integer $commentEditorId - ID of user who is comment's editor
  * @param string[] $arFields - fields to be updated, including text in BB code
  * 
  * @throws TasksException, CTaskAssertException
  * 
  * @return boolean
  */
 public static function update($taskId, $commentId, $commentEditorId, $arFields)
 {
     CTaskAssert::assertLaxIntegers($taskId, $commentId, $commentEditorId);
     CTaskAssert::assert(is_array($arFields) && !empty($arFields));
     if (!CModule::includeModule('forum')) {
         throw new TasksException('forum module can not be loaded', TasksException::TE_ACTION_FAILED_TO_BE_PROCESSED);
     }
     IncludeModuleLangFile(__FILE__);
     $forumId = CTasksTools::GetForumIdForIntranet();
     $oTask = CTaskItem::getInstance($taskId, $commentEditorId);
     $arTask = $oTask->getData();
     $outForumTopicId = $outStrUrl = null;
     $arErrorCodes = array();
     $arFields = array_merge(array('EDITOR_ID' => $commentEditorId), $arFields);
     $messageId = self::__deprecated_Add($arFields['POST_MESSAGE'], $forumTopicId = $arTask['FORUM_TOPIC_ID'], $forumId, $nameTemplate = CSite::GetNameFormat(false), $arTask = $arTask, $permissions = 'Y', $commentId = $commentId, $givenUserId = $commentEditorId, $imageWidth = 300, $imageHeight = 300, $arSmiles = array(), $arForum = CForumNew::GetByID($forumId), $messagesPerPage = 10, $arUserGroupArray = CUser::GetUserGroup($commentEditorId), $backPage = null, $strMsgAddComment = GetMessage("TASKS_COMMENT_MESSAGE_ADD"), $strMsgEditComment = GetMessage("TASKS_COMMENT_MESSAGE_EDIT"), $strMsgNewTask = GetMessage("TASKS_COMMENT_SONET_NEW_TASK_MESSAGE"), $componentName = null, $outForumTopicId, $arErrorCodes, $outStrUrl, $arFields);
     if (!($messageId >= 1)) {
         throw new TasksException(serialize($arErrorCodes), TasksException::TE_ACTION_FAILED_TO_BE_PROCESSED | TasksException::TE_FLAG_SERIALIZED_ERRORS_IN_MESSAGE);
     }
     return true;
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:32,代码来源:taskcomments.php

示例11: _determineModules

 protected function _determineModules(array $ids)
 {
     sort($ids);
     $cache = new CPhpCache();
     if ($cache->initCache($this->_cacheTime, serialize($ids), $this->_cacheDir)) {
         return $cache->getVars();
     }
     CModule::includeModule('iblock');
     $res = CIBlockElement::getList(array(), array('ID' => $ids), false, array('nTopCount' => count($ids)), array('ID', 'IBLOCK_ID'));
     $result = array();
     while ($row = $res->fetch()) {
         $module = $this->_getModule($row['IBLOCK_ID']);
         if (!array_key_exists($module, $result)) {
             $result[$module] = array();
         }
         $result[$module][] = $row['ID'];
     }
     if ($cache->startDataCache()) {
         $cache->endDataCache($result);
     }
     return $result;
 }
开发者ID:irotaev,项目名称:vector-vip.server,代码行数:22,代码来源:Url.php

示例12: getServiceName

<?php

if (!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED !== true) {
    die;
}
if (!CModule::includeModule('webdav')) {
    return;
}
class CWebDavDocEditSkydriveComponent extends CWebDavEditDocComponentBase
{
    /**
     * @return string
     */
    protected function getServiceName()
    {
        return CWebDavLogOnlineEdit::SKYDRIVE_SERVICE_NAME;
    }
    /**
     * @return string
     */
    protected function generateUriToDoc()
    {
        return CUtil::JSEscape($this->getWebdav()->uri . '?' . 'editIn=' . $this->getServiceName() . '&proccess=1');
    }
    protected function getAccessTokenBySocServ()
    {
        $socGoogleOAuth = new CSocServLiveIDOAuth($this->getUser()->getId());
        //this bug. SocServ fill entityOAuth in method getUrl.....
        $liveIdOAuthUrl = $socGoogleOAuth->getUrl('modal', CWebDavEditSkyDrive::$SCOPE);
        $accessToken = $socGoogleOAuth->getStorageToken();
        return $accessToken;
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:31,代码来源:class.php

示例13: initSession

 protected function initSession()
 {
     if ($domain = $GLOBALS["APPLICATION"]->getCookieDomain()) {
         ini_set("session.cookie_domain", $domain);
     }
     if (\COption::getOptionString("security", "session", "N") === "Y" && \CModule::includeModule("security")) {
         \CSecuritySession::init();
     }
     //diagnostic for spaces in init.php etc.
     //message is shown in the admin section
     $GLOBALS["aHeadersInfo"] = array();
     if (headers_sent($hs_file, $hs_line)) {
         $GLOBALS["aHeadersInfo"] = array("file" => $hs_file, "line" => $hs_line);
     }
     session_start();
 }
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:16,代码来源:httpapplication.php

示例14: htmlspecialcharsex

}
$arParams["CAN_EDIT"] = !$arResult["IS_SOCNET_GROUP_CLOSED"] && ($lists_perm >= CListPermissions::IS_ADMIN || CIBlockRights::UserHasRightTo($IBLOCK_ID, $IBLOCK_ID, "iblock_edit"));
$arResult["CAN_ADD_ELEMENT"] = !$arResult["IS_SOCNET_GROUP_CLOSED"] && ($lists_perm > CListPermissions::CAN_READ || CIBlockSectionRights::UserHasRightTo($IBLOCK_ID, $section_id, "section_element_bind"));
$arResult["CAN_READ"] = !$arResult["IS_SOCNET_GROUP_CLOSED"] && ($lists_perm > CListPermissions::CAN_READ || CIBlockSectionRights::UserHasRightTo($IBLOCK_ID, $section_id, "element_read"));
$arResult["CAN_EDIT_SECTIONS"] = !$arResult["IS_SOCNET_GROUP_CLOSED"] && ($lists_perm >= CListPermissions::CAN_WRITE || CIBlockSectionRights::UserHasRightTo($IBLOCK_ID, $section_id, "section_edit") || CIBlockSectionRights::UserHasRightTo($IBLOCK_ID, $section_id, "section_section_bind"));
$arResult["IBLOCK_PERM"] = $lists_perm;
$arResult["USER_GROUPS"] = $USER->GetUserGroupArray();
$arIBlock = CIBlock::GetArrayByID(intval($arParams["~IBLOCK_ID"]));
$arResult["~IBLOCK"] = $arIBlock;
$arResult["IBLOCK"] = htmlspecialcharsex($arIBlock);
$arResult["IBLOCK_ID"] = $arIBlock["ID"];
$arResult["PROCESSES"] = false;
$arResult["USE_COMMENTS"] = false;
$arResult["RAND_STRING"] = $this->randString();
if ($arParams["IBLOCK_TYPE_ID"] == COption::GetOptionString("lists", "livefeed_iblock_type_id")) {
    $arResult["USE_COMMENTS"] = (bool) CModule::includeModule("forum");
    $arResult["PROCESSES"] = true;
}
if ($arResult["IBLOCK"]["BIZPROC"] == "Y" && CModule::IncludeModule('bizproc')) {
    $arParams["CAN_EDIT_BIZPROC"] = !$arResult["IS_SOCNET_GROUP_CLOSED"] && CBPDocument::CanUserOperateDocumentType(CBPCanUserOperateOperation::CreateWorkflow, $USER->GetID(), BizProcDocument::generateDocumentComplexType($arParams["IBLOCK_TYPE_ID"], $IBLOCK_ID), array("UserGroups" => $USER->GetUserGroupArray()));
}
if (isset($arParams["SOCNET_GROUP_ID"]) && $arParams["SOCNET_GROUP_ID"] > 0) {
    $arParams["SOCNET_GROUP_ID"] = intval($arParams["SOCNET_GROUP_ID"]);
} else {
    $arParams["SOCNET_GROUP_ID"] = "";
}
$arResult["GRID_ID"] = "lists_list_elements_" . $arResult["IBLOCK_ID"];
$arResult["ANY_SECTION"] = isset($_GET["list_section_id"]) && strlen($_GET["list_section_id"]) == 0;
$arResult["SECTION"] = false;
$arResult["SECTION_ID"] = false;
$arResult["PARENT_SECTION_ID"] = false;
开发者ID:webgksupport,项目名称:alpina,代码行数:31,代码来源:component.php

示例15: includeModule

 public function includeModule()
 {
     parent::includeModule(['user.controllers', 'user.models']);
 }
开发者ID:ennjamusic,项目名称:study,代码行数:4,代码来源:UserModule.php


注:本文中的CModule::includeModule方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。