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


PHP CMain::finalActions方法代码示例

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


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

示例1: end

 /**
  * Terminates controller and application.
  * This method replaces "die()" or "exit()" and ensures life cycle of application.
  * @return void
  */
 protected function end()
 {
     $this->logDebugInfo();
     /** @noinspection PhpUndefinedClassInspection */
     \CMain::finalActions();
     die;
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:12,代码来源:controller.php

示例2: end

 protected function end($terminate = true)
 {
     Diag::getInstance()->logDebugInfo($this->getName());
     if ($terminate) {
         /** @noinspection PhpUndefinedClassInspection */
         \CMain::finalActions();
         die;
     }
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:9,代码来源:basecomponent.php

示例3: showJsonAnswer

 protected function showJsonAnswer($result)
 {
     if (!defined("PUBLIC_AJAX_MODE")) {
         define("PUBLIC_AJAX_MODE", true);
     }
     if (!defined("NO_KEEP_STATISTIC")) {
         define("NO_KEEP_STATISTIC", "Y");
     }
     if (!defined("NO_AGENT_STATISTIC")) {
         define("NO_AGENT_STATISTIC", "Y");
     }
     if (!defined("NO_AGENT_CHECK")) {
         define("NO_AGENT_CHECK", true);
     }
     if (!defined("DisableEventsCheck")) {
         define("DisableEventsCheck", true);
     }
     require_once $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/main/include/prolog_before.php";
     $GLOBALS["APPLICATION"]->RestartBuffer();
     while (ob_end_clean()) {
     }
     $version = IsIE();
     if (!(0 < $version && $version < 10)) {
         header('Content-Type:application/json; charset=UTF-8');
     }
     echo Json::encode($result);
     \CMain::finalActions();
     die;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:29,代码来源:uploader.php

示例4: intval

            $arRes = CSocNetLogComponent::getCommentByRequest($comment_id, $post_id, "edit");
            if ($arRes) {
                $arResult["id"] = intval($arRes["ID"]);
                $arResult["message"] = str_replace("<br />", "\n", $arRes["MESSAGE"]);
                $arResult["sourceId"] = intval($arRes["SOURCE_ID"]) > 0 ? intval($arRes["SOURCE_ID"]) : intval($arRes["ID"]);
                $arResult["UF"] = !empty($arRes["UF"]) ? $arRes["UF"] : array();
            }
        }
    } elseif ($action == "delete_comment") {
        $arResult = false;
        $comment_id = intval($_REQUEST["delete_comment_id"]);
        $post_id = intval($_REQUEST["post_id"]);
        if ($comment_id > 0 && $post_id > 0) {
            $arRes = CSocNetLogComponent::getCommentByRequest($comment_id, $post_id, "delete");
            if ($arRes) {
                $bSuccess = CSocNetLogComments::Delete($arRes["ID"], true);
                if (!$bSuccess && ($e = $GLOBALS["APPLICATION"]->GetException())) {
                    $errorMessage = $e->GetString();
                }
                $APPLICATION->IncludeComponent("bitrix:main.post.list", "", array("ENTITY_XML_ID" => $_REQUEST["ENTITY_XML_ID"], "PUSH&PULL" => array("ID" => $bSuccess ? $arRes["SOURCE_ID"] > 0 ? $arRes["SOURCE_ID"] : $arRes["ID"] : false, "ACTION" => "DELETE"), "OK_MESSAGE" => $bSuccess ? GetMessage('SONET_LOG_COMMENT_DELETED') : '', "ERROR_MESSAGE" => !$bSuccess ? $errorMessage : ''));
            }
        }
    }
    header('Content-Type:application/json; charset=UTF-8');
    echo \Bitrix\Main\Web\Json::encode($arResult);
    /** @noinspection PhpUndefinedClassInspection */
    \CMain::finalActions();
    die;
}
define('PUBLIC_AJAX_MODE', true);
require_once $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/main/include/epilog_after.php";
开发者ID:Satariall,项目名称:izurit,代码行数:31,代码来源:ajax.php

示例5: sendJsonResponse

 protected function sendJsonResponse($response)
 {
     $this->getApplication()->restartBuffer();
     while (ob_end_clean()) {
     }
     header('Content-Type:application/json; charset=UTF-8');
     echo Json::encode($response);
     /** @noinspection PhpUndefinedClassInspection */
     \CMain::finalActions();
     die;
 }
开发者ID:webgksupport,项目名称:alpina,代码行数:11,代码来源:class.php

示例6: end

 protected function end($terminate = true)
 {
     if (IsModuleInstalled("disk")) {
         \Bitrix\Disk\Internals\Diag::getInstance()->logDebugInfo($this->getName());
     }
     if ($terminate) {
         /** @noinspection PhpUndefinedClassInspection */
         \CMain::finalActions();
         die;
     }
 }
开发者ID:Satariall,项目名称:izurit,代码行数:11,代码来源:class.php


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