• Resolved Redyan

    (@redyan)


    Good morning everyone,
    within the detail of each product, if I choose the Variations item from the menu and expand a single variation, I have the following error:

    Warning: Undefined array key "id" in /wp-content/plugins/woocommerce/includes/admin/wc-meta-box-functions.php on line 68
    
    Warning: Undefined array key "id" in /wp-content/plugins/woocommerce/includes/admin/wc-meta-box-functions.php on line 69
    
    Custom name
    
    Warning: Undefined array key "id" in /wp-content/plugins/woocommerce/includes/admin/wc-meta-box-functions.php on line 75

    Unfortunately I have no idea how to fix the problem. WordPress version is updated to 6.0.2 with PHP 8

    Can anyone help me?

    Thank you!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Redyan

    (@redyan)

    After a debugging session I found the source of the error. Is a wordpress theme plugin (BoldThemes WordPress Importer). I will open a ticket to their support service. Thank you all and sorry for the inconvenience.

    @redyan I’m hitting the same thing on a custom theme. Did you ever figure this out? I’ve hit this on another site and it has me looking for an alternative.

    When I dump the $variation variable, I get:

    Array
    (
    [name] => woovr_name[16337]
    [label] => Custom name
    [value] =>
    [placeholder] =>
    [class] => short
    [style] =>
    [wrapper_class] =>
    [type] => text
    [desc_tip] =>
    )

    There is no key/index of id.

    Seems like there should be a wp_parse_args() there or something to make sure all required attributes are there.

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