本文整理匯總了PHP中CBlog::SendPing方法的典型用法代碼示例。如果您正苦於以下問題:PHP CBlog::SendPing方法的具體用法?PHP CBlog::SendPing怎麽用?PHP CBlog::SendPing使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類CBlog
的用法示例。
在下文中一共展示了CBlog::SendPing方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: htmlspecialcharsEx
$dbSite = CSite::GetByID(SITE_ID);
$arSite = $dbSite->Fetch();
$serverName = htmlspecialcharsEx($arSite["SERVER_NAME"]);
if (strlen($serverName) <= 0) {
if (defined("SITE_SERVER_NAME") && strlen(SITE_SERVER_NAME) > 0) {
$serverName = SITE_SERVER_NAME;
} else {
$serverName = COption::GetOptionString("main", "server_name", "");
}
if (strlen($serverName) <= 0) {
$serverName = $_SERVER["SERVER_NAME"];
}
}
}
$blogUrl = "http://" . $serverName . CComponentEngine::MakePathFromTemplate(htmlspecialcharsBack($arParams["PATH_TO_BLOG"]), array("blog" => $arBlog["URL"], "user_id" => $arBlog["OWNER_ID"], "group_id" => $arBlog["SOCNET_GROUP_ID"]));
CBlog::SendPing($arBlog["NAME"], $blogUrl);
}
}
}
if ($newID > 0 && strlen($arResult["ERROR_MESSAGE"]) <= 0) {
if ($arFields["PUBLISH_STATUS"] == BLOG_PUBLISH_STATUS_PUBLISH) {
BXClearCache(true, "/" . SITE_ID . "/blog/last_messages_list/");
$arFieldsIM = array("TYPE" => "POST", "TITLE" => $arFields["TITLE"], "URL" => CComponentEngine::MakePathFromTemplate(htmlspecialcharsBack($arParams["PATH_TO_POST"]), array("post_id" => $newID, "user_id" => $arBlog["OWNER_ID"])), "ID" => $newID, "FROM_USER_ID" => $arParams["USER_ID"], "TO_USER_ID" => array(), "TO_SOCNET_RIGHTS" => $arFields["SOCNET_RIGHTS"], "TO_SOCNET_RIGHTS_OLD" => $socnetRightsOld["U"]);
if (!empty($arMentionOld)) {
$arFieldsIM["MENTION_ID_OLD"] = $arMentionOld[1];
}
if (!empty($arMention)) {
$arFieldsIM["MENTION_ID"] = $arMention[1];
}
CBlogPost::NotifyIm($arFieldsIM);
}