• Resolved dragon013

    (@dragon013)


    Hello,

    my server runs at PHP 8.1 now and since then I get these errors:

    Warning: Undefined array key “HTTP_HOST” in /<path to wordpress>/wp-content/plugins/ip2location-country-blocker/ip2location-country-blocker.php on line 2960

    Warning: Trying to access array offset on value of type bool in /<path to wordpress>//wp-content/plugins/ip2location-country-blocker/ip2location-country-blocker.php on line 2970

    I am running wpcron.php via a cron job to avoid waiting for a visitor triggering the wordpress cronjobs (and I would like to keep that method). I guess because of this I get the errors ? (I had the same with a self written script). It help (at least for the HTTP_HOST) to check if value is set before using it.

    wpcron.php is called with php /path/to/wpcron.php

    Could you please have a look into it ? Thanks in a advance.

    Dragon013

    • This topic was modified 2 years, 4 months ago by dragon013.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘PHP Errors when running wpcron.php via Cronjob’ is closed to new replies.