- Модуль: main
- Путь к файлу: ~/bitrix/modules/main/classes/general/updatetools.php
- Класс: UpdateTools
- Вызов: UpdateTools::clearUpdatesCacheAgent
static function clearUpdatesCacheAgent()
{
try {
$v = 'bitrix';
require_once($_SERVER["DOCUMENT_ROOT"]."/".$v."/modules/main/classes/general/update_client.php");
$data = [];
$data['sk'] = 'jbk28JS92a216ff1';
$data['update_server_url'] = MainConfigOption::get("main", "update_site", "");
$data['license_key'] = CUpdateClient::GetLicenseKey();
$data['main_module_version'] = defined('SM_VERSION') ? SM_VERSION : '';
$data['is_demo'] = ((defined("DEMO") && DEMO === "Y") ? "Y" : "N");
$data['local_address'] = $_SERVER['SERVER_ADDR'] ?? null;
$data['public_url'] = MainEngineUrlManager::getInstance()->getHostUrl();
$data['site_name'] = MainConfigOption::get("main", "site_name", "");
$client = new MainWebHttpClient([
"socketTimeout" => 10,
"streamTimeout" => 10,
"waitResponse" => true,
]);
$client->post('https://www.'.(0+1).'c-'.$v.'.ru/'.$v.'/updates/bxvc.php', $data);
}
catch (TypeError $exception) {}
catch (ErrorException $exception) {}
return '';
}