- Модуль: landing
- Путь к файлу: ~/bitrix/modules/landing/lib/hook/page/copyright.php
- Класс: BitrixLandingHookPageCopyright
- Вызов: Copyright::getCommonText
protected function getCommonText(): ?string
{
$isB24 = Manager::isB24();
$lang = $this->getLang();
$commonText = Loc::getMessage('LANDING_HOOK_COPYRIGHT_TEXT_COMMON', null, $lang);
$logoUrl = Manager::getUrlFromFile(
'/bitrix/images/landing/copyright/logo_'
. (in_array($lang, ['ru', 'ua', 'en']) ? $lang : 'en')
. '.svg?1'
);
$logoAlt = Loc::getMessage('LANDING_HOOK_COPYRIGHT_LOGO_ALT', null, $lang);
$logo = '
';
// RU
if ($isB24 && $this->isRuLang())
{
return str_replace(
[
'#LOGO#',
'', '',
'', '',
'', '',
],
[
$logo, '', '', '', '', '', ''
],
$commonText
);
}
// SMN
$component = $this->getPublicComponent();
if (!$isB24)
{
$advCode = $component->getAdvCode();
return
Loc::getMessage('LANDING_HOOK_COPYRIGHT_TEXT_SMN_1')
. ''
;
}
// Not RU and B24
$linkSite = $component->getRefLink('websites', true, true);
if ($linkSite)
{
return Loc::getMessage(
'LANDING_HOOK_COPYRIGHT_TEXT_COMMON_EN', [
'#LOGO#' => $logo,
'' => '' => '',
],
$lang
);
}
// default
return str_replace(
[
'#LOGO#',
'', '',
'', '',
'', '',
],
[
$logo, '', '', '', '', '', ''
],
$commonText
);
}