mirror of
https://github.com/e107inc/e107.git
synced 2025-07-31 03:40:37 +02:00
Issue #5079 Warnings when running cron.php
This commit is contained in:
3
cron.php
3
cron.php
@@ -34,8 +34,9 @@ $_E107['no_menus'] = true;
|
||||
$_E107['allow_guest'] = true; // allow crons to run while in members-only mode.
|
||||
$_E107['no_maintenance'] = true;
|
||||
|
||||
if (php_sapi_name() !== "cli" && $_E107['debug'] === false)
|
||||
if ((PHP_SAPI === "apache" || PHP_SAPI === "litespeed") && $_E107['debug'] === false)
|
||||
{
|
||||
error_log("e107: cron.php was blocked from executing with PHP_SAPI: ".php_sapi_name(), E_USER_NOTICE);
|
||||
header('HTTP/1.0 403 Forbidden');
|
||||
echo "<h1>Access Denied</h1>";
|
||||
exit;
|
||||
|
Reference in New Issue
Block a user