• Hi.

    When I try to add API key in the plugin settings I get an error:

     Fatal error: Uncaught Error: array_merge(): Argument #1 must be of type array, bool given
    in /var/www/vhosts/pikaluna.com/dev.pikaluna.com/wp-content/plugins/klaviyo/inc/kla-admin.php on line 171
    
    Call stack:
    
    array_merge()
    wp-content/plugins/klaviyo/inc/kla-admin.php:171
    WPKlaviyoAdmin::process_settings()
    wp-content/plugins/klaviyo/inc/kla-admin.php:57
    WPKlaviyoAdmin::settings()
    wp-includes/class-wp-hook.php:303
    WP_Hook::apply_filters()
    wp-includes/class-wp-hook.php:327
    WP_Hook::do_action()
    wp-includes/plugin.php:470
    do_action()
    wp-admin/admin.php:259

    I also tried to change to default wordpress theme but the error stays the same. We use PHP 8, maybe this is the problem?

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

    (@klaviyo)

    @domen66 could you share what version of WordPress and Woocommerce you have installed? Where were you seeing this error on the WordPress Admin or within a log file? I tried to test by doing this via MAMP but couldn’t reproduce.

    • This reply was modified 2 years, 10 months ago by klaviyo.
    Thread Starter domen66

    (@domen66)

    @klaviyo I am using woocommerce 5.9.0 and wordpress 5.8.2. Even if I update woocommerce to the latest version, the error is the same. I got this error in WordPress Admin.

    We are also using wordpress multisite. When I activate plugin only on specific site (not network), the error on wordpress admin that I mentioned disappears but when I add API key it won’t save it. If I look in server logs I get an error:

    
    12:38
    AH01071: Got error 'PHP message: PHP Warning: Trying to access array offset on value of type bool in /var/www/vhosts/pikaluna.com/pikaluna.com/wp-content/plugins/klaviyo/includes/class-wpklaviyo.php on line 26PHP message: PHP Warning: Trying to access array offset on value of type bool in /var/www/vhosts/pikaluna.com/pikaluna.com/wp-content/plugins/klaviyo/includes/class-wpklaviyo.php on line 52', referer: https://pikaluna.com/de/wp-admin/plugins.php
    
    AH01071: Got error 'PHP message: PHP Warning: Undefined array key "klaviyo_subscribe_checkbox" in /var/www/vhosts/pikaluna.com/pikaluna.com/wp-content/plugins/klaviyo/inc/kla-admin.php on line 105', referer: https://pikaluna.com/de/wp-admin/plugins.php?plugin_status=all&paged=1&s
    
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Can’t use plugin with PHP 8’ is closed to new replies.