} } } if (IntVal($arResult["ajax_comment"]) <= 0) { $arResult["ERROR_MESSAGE"] = GetMessage("B_B_PC_MES_ERROR_SHOW"); } } elseif (IntVal($_GET["hide_comment_id"]) > 0) { $arComment = CBlogComment::GetByID(IntVal($_GET["hide_comment_id"])); if ($arResult["Perm"] >= BLOG_PERMS_MODERATE && !empty($arComment)) { if ($arComment["PUBLISH_STATUS"] != BLOG_PUBLISH_STATUS_PUBLISH) { $arResult["ERROR_MESSAGE"] = GetMessage("B_B_PC_MES_ERROR_SHOW"); } else { if (check_bitrix_sessid()) { if ($commentID = CBlogComment::Update($arComment["ID"], array("PUBLISH_STATUS" => BLOG_PUBLISH_STATUS_READY))) { BXClearCache(true, "/blog/comment/" . intval($arParams["ID"] / 100) . "/" . $arParams["ID"] . "/"); CBlogComment::DeleteLog($arComment["ID"]); $arResult["ajax_comment"] = $arComment["ID"]; } } else { $arResult["ERROR_MESSAGE"] = GetMessage("B_B_PC_MES_ERROR_SESSION"); } } } if (IntVal($arResult["ajax_comment"]) <= 0 && strlen($arResult["ERROR_MESSAGE"]) <= 0) { $arResult["ERROR_MESSAGE"] = GetMessage("B_B_PC_MES_ERROR_HIDE"); } } elseif (IntVal($_GET["hidden_add_comment_id"]) > 0) { $arResult["MESSAGE"] = GetMessage("B_B_PC_MES_HIDDEN_ADDED"); } $arResult["CanUserComment"] = false; $arResult["canModerate"] = false;