本文整理汇总了PHP中CJSCore::GetInlineCoreJs方法的典型用法代码示例。如果您正苦于以下问题:PHP CJSCore::GetInlineCoreJs方法的具体用法?PHP CJSCore::GetInlineCoreJs怎么用?PHP CJSCore::GetInlineCoreJs使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CJSCore
的用法示例。
在下文中一共展示了CJSCore::GetInlineCoreJs方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: EndBufferContent
public function EndBufferContent($content = "")
{
if ($this->buffer_man) {
$this->auto_buffer_cleaned = true;
return "";
}
Frame::checkAdminPanel();
if (function_exists("getmoduleevents")) {
foreach (GetModuleEvents("main", "OnBeforeEndBufferContent", true) as $arEvent) {
ExecuteModuleEventEx($arEvent, array());
}
}
$asset = Asset::getInstance();
if (Frame::getUseAppCache()) {
$asset->addString(CJSCore::GetCoreMessagesScript(), false, AssetLocation::AFTER_CSS, AssetMode::ALL);
} else {
$asset->addString(CJSCore::GetCoreMessagesScript(), false, AssetLocation::AFTER_CSS, AssetMode::STANDARD);
$asset->addString(CJSCore::GetCoreMessagesScript(true), false, AssetLocation::AFTER_CSS, AssetMode::COMPOSITE);
}
$asset->addString($this->GetSpreadCookieHTML(), false, AssetLocation::AFTER_JS, AssetMode::STANDARD);
if ($asset->canMoveJsToBody() && \CJSCore::IsCoreLoaded()) {
$asset->addString(\CJSCore::GetInlineCoreJs(), false, AssetLocation::BEFORE_CSS, AssetMode::ALL);
}
if (is_object($GLOBALS["APPLICATION"])) {
$cnt = count($this->buffer_content_type);
for ($i = 0; $i < $cnt; $i++) {
$this->buffer_content[$i * 2 + 1] = call_user_func_array($this->buffer_content_type[$i]["F"], $this->buffer_content_type[$i]["P"]);
}
}
$composite = Frame::getInstance();
$compositeContent = $composite->startBuffering($content);
$content = implode("", $this->buffer_content) . $content;
if (function_exists("getmoduleevents")) {
foreach (GetModuleEvents("main", "OnEndBufferContent", true) as $arEvent) {
ExecuteModuleEventEx($arEvent, array(&$content));
}
}
$wasContentModified = $composite->endBuffering($content, $compositeContent);
if (!$wasContentModified && $asset->canMoveJsToBody()) {
$asset->moveJsToBody($content);
}
return $content;
}