• Resolved Linn

    (@linnalexandra)


    We’re receiving this warning on PHP 8.2:

    PHP Warning:? Undefined array key "HTTP_ACCEPT_LANGUAGE" in /wp-content/plugins/countdown-builder/classes/countdown/CircleCountdown.php on line 182

    I copied the change you made in SimpleCountdown.php to fix the same error, changing line 182 of CircleCountdown.php from this:

    $lang = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2);

    to this:

    $serverLang = '';
    if (!empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {
        $serverLang = $_SERVER['HTTP_ACCEPT_LANGUAGE'];
    }
    $lang = substr($serverLang, 0, 2);

    and that fixed it, but obviously we’d prefer a permanent fix in the plugin ?? Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author adamskaat

    (@adamskaat)

    Hi @linnalexandra,

    Thank you for your request and help.
    We fixed that and other issues on our latest version, please update and let me know about your progress.

    Also i would like to know do you have any new feature suggestions?

    Thread Starter Linn

    (@linnalexandra)

    The update fixed it, thanks so much for the speedy reply! I can’t think of any feature suggestions but I will let you know ??

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Undefined array key “HTTP_ACCEPT_LANGUAGE”’ is closed to new replies.