• Resolved Stefano Lissa

    (@satollo)


    Hi, a little warning that anyway does not affect the correct functioning. When the wp-cron.php is triggered using the php command (and not an http call) this warning is recorded:

    PHP Warning:  Undefined array key "SERVER_PROTOCOL" in .../wp-content/plugins/awesome-support/includes/functions-general.php on line 202
    PHP Warning:  Undefined array key "SERVER_NAME" in .../wp-content/plugins/awesome-support/includes/functions-general.php on line 203
    PHP Warning:  Undefined array key "SERVER_PORT" in .../wp-content/plugins/awesome-support/includes/functions-general.php on line 203

    with PHP 8.0.

    Bye, Stefano.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Hi @satollo

    Thank you for sharing the details. Can you please check if you are using the latest version of awesome support v6.0.12? If not please update and share the version you are using to investigate it.

    Regards

    Thread Starter Stefano Lissa

    (@satollo)

    Hi, sorry for this late follow-up: yes we’re using the latest version.

    Stefano.

    Plugin Author Yeison Baron

    (@yeisonbp)

    Hi @satollo,

    We released a patch update. Let us know if this solves your issue.

    Best Regards.

    Thread Starter Stefano Lissa

    (@satollo)

    Thanks!

    Thread Starter Stefano Lissa

    (@satollo)

    Hi, the warning is still there. You probably added the check on “is_cli()”, but the wp-cron.php can be triggered using a simple “php” command line command. You should even check the presence of $_SERVER value like:

    } elseif ( wpas_is_wp_cli() || empty($_SERVER[‘SERVER_NAME’])) {

    on functions-general.php.

    Thanks!

    Plugin Author Yeison Baron

    (@yeisonbp)

    Hi @satollo,

    I sent a report to the developers to apply the fix to PHP 8.0 version to fix it in an upcoming release.

    Thanks!

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘A PHP Warning when the cron is started with php command’ is closed to new replies.