Skip to content

Instantly share code, notes, and snippets.

@belukov
Last active April 2, 2016 13:33
Show Gist options
  • Select an option

  • Save belukov/59e5147b3565b5b9048a to your computer and use it in GitHub Desktop.

Select an option

Save belukov/59e5147b3565b5b9048a to your computer and use it in GitHub Desktop.
bitrix cron_events.php (bitrix/php_interface/cron_events.php)
<?php
$_SERVER["DOCUMENT_ROOT"] = realpath(dirname(__FILE__)."/../..");
$DOCUMENT_ROOT = $_SERVER["DOCUMENT_ROOT"];
define("NO_KEEP_STATISTIC", true);
define("NOT_CHECK_PERMISSIONS",true);
define('BX_NO_ACCELERATOR_RESET', true);
define('CHK_EVENT', true);
require($_SERVER["DOCUMENT_ROOT"]."/bitrix/modules/main/include/prolog_before.php");
@set_time_limit(0);
@ignore_user_abort(true);
CAgent::CheckAgents();
define("BX_CRONTAB_SUPPORT", true);
CEvent::CheckEvents();
if(CModule::IncludeModule('sender'))
{
\Bitrix\Sender\MailingManager::checkPeriod(false);
\Bitrix\Sender\MailingManager::checkSend();
}
define("BX_CRONTAB", true);
require($_SERVER['DOCUMENT_ROOT']."/bitrix/modules/main/tools/backup.php");
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment