$APPLICATION->SetTitle(GetMessage("SENDER_SUBSCR_TITLE"), array('COMPONENT_NAME' => $this->GetName())); } //get site's newsletter categories $obCache = new CPHPCache(); $strCacheID = LANG . $arParams["SHOW_HIDDEN"]; if ($obCache->StartDataCache($arParams["CACHE_TIME"], $strCacheID, "/" . SITE_ID . $this->GetRelativePath())) { if (!CModule::IncludeModule("sender")) { $obCache->AbortDataCache(); ShowError(GetMessage("SENDER_SUBSCR_MODULE_NOT_INSTALLED")); return; } $arFilter = array("SITE_ID" => SITE_ID); if (!$arParams["SHOW_HIDDEN"]) { $arFilter["IS_PUBLIC"] = "Y"; } $mailingList = \Bitrix\Sender\Subscription::getMailingList($arFilter); $obCache->EndDataCache($mailingList); } else { $mailingList = $obCache->GetVars(); } if (strlen($_REQUEST["SENDER_SUBSCRIBE_EMAIL"]) > 0) { $arResult["EMAIL"] = htmlspecialcharsbx($_REQUEST["SENDER_SUBSCRIBE_EMAIL"]); } elseif (strlen($arSubscription["EMAIL"]) > 0) { $arResult["EMAIL"] = htmlspecialcharsbx($arSubscription["EMAIL"]); } else { $arResult["EMAIL"] = ""; } if (!is_array($mailingList)) { $mailingList = array(); } $arResult["RUBRICS"] = array();