_HTML_BG_CRON_FORCE

The constant _HTML_BG_CRON_FORCE inhibits cron release by fsockopen/cURL.

  • New in : SPIP 3.0

The constant _HTML_BG_CRON_FORCE responds to the problem found on some servers whose firewall is set to silently DROP any outgoing http request: fsockopen then waits 30s to launch the request at each hit before giving back the hand. cURL does not wait for it but does not know that its request fails. Result the CRON never runs and the site has a catastrophic response time...

If you know that you are on such a configuration (and that you cannot change it) it is possible to define the value of the constant
_HTML_BG_CRON_FORCE in your file
config/mes_options.php (See the article dedicated to it).

Example :

// to greatly reduce site response times,
// do not throw the cron by fsockopen/cURL
// because the server configuration does not allow it.
define('_HTML_BG_CRON_FORCE', TRUE);
  

This setting also restores the operation of CRON jobs in case your site is protected by a pair of files .htaccess / .htpasswd (see constant _DIRECT_CRON_FORCE).

Author jack Published : Updated : 18/04/23

Translations : English, français, Nederlands