Created
July 19, 2017 09:27
-
-
Save 4yvi/cc288a35f4a20f2167924045deb9048c to your computer and use it in GitHub Desktop.
Файл для Битрикс, который запускается через cron
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/php | |
<?php | |
$_SERVER['DOCUMENT_ROOT'] = '/home/site/www'; | |
$DOCUMENT_ROOT = $_SERVER['DOCUMENT_ROOT']; | |
// Запрешяем сбор статистики | |
define('NO_KEEP_STATISTIC', true); | |
// Запрет на проверку прав | |
define('NOT_CHECK_PERMISSIONS', true); | |
// Отключам лимит | |
set_time_limit(0); | |
// Устанавливаем язык | |
define('LANG', 'ru'); | |
// Подключаем ядро Битрикс | |
require_once($_SERVER['DOCUMENT_ROOT'] . "/bitrix/modules/main/include/prolog_before.php"); | |
// код... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment