Home › Forums › WoodMart support forum › Some warning and notices coming from wph-widget-class.php
Some warning and notices coming from wph-widget-class.php
- This topic has 9 replies, 3 voices, and was last updated 2 years, 10 months ago by Artem Temos.
-
AuthorPosts
-
January 8, 2022 at 11:37 am #344122
horny_fungusParticipantHi, recently I saw following messages in my error log:
Notice: Undefined index: fields in /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php on line 538 Stack Trace 1. {main}() /wp-admin/customize.php:0 2. do_action() /wp-admin/customize.php:123 3. WP_Hook->do_action() /wp-includes/plugin.php:470 4. WP_Hook->apply_filters() /wp-includes/class-wp-hook.php:327 5. WP_Customize_Widgets->enqueue_scripts() /wp-includes/class-wp-hook.php:303 6. WP_Customize_Widgets->get_available_widgets() /wp-includes/class-wp-customize-widgets.php:712 7. WP_Customize_Widgets->get_widget_control() /wp-includes/class-wp-customize-widgets.php:1070 8. wp_widget_control() /wp-includes/class-wp-customize-widgets.php:1122 9. WOODMART_Banner_Widget->form_callback() /wp-admin/includes/widgets.php:274 10. WOODMART_Banner_Widget->form() /wp-includes/class-wp-widget.php:534 11. WOODMART_Banner_Widget->create_fields() /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php:76 12. WOODMART_Banner_Widget->create_field() /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php:327 13. WOODMART_Banner_Widget->create_field_dropdown() /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php:433
Warning: Invalid argument supplied for foreach() in /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php on line 538 Stack Trace 1. {main}() /wp-admin/customize.php:0 2. do_action() /wp-admin/customize.php:123 3. WP_Hook->do_action() /wp-includes/plugin.php:470 4. WP_Hook->apply_filters() /wp-includes/class-wp-hook.php:327 5. WP_Customize_Widgets->enqueue_scripts() /wp-includes/class-wp-hook.php:303 6. WP_Customize_Widgets->get_available_widgets() /wp-includes/class-wp-customize-widgets.php:712 7. WP_Customize_Widgets->get_widget_control() /wp-includes/class-wp-customize-widgets.php:1070 8. wp_widget_control() /wp-includes/class-wp-customize-widgets.php:1122 9. WOODMART_Banner_Widget->form_callback() /wp-admin/includes/widgets.php:274 10. WOODMART_Banner_Widget->form() /wp-includes/class-wp-widget.php:534 11. WOODMART_Banner_Widget->create_fields() /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php:76 12. WOODMART_Banner_Widget->create_field() /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php:327 13. WOODMART_Banner_Widget->create_field_dropdown() /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php:433
Unfortunately I have no idea what triggered the warning, supposedly some front-end activity.
Can you please check what could happen and also tell me to what theme element this is related? Is this about header promo banner?January 8, 2022 at 11:51 am #344124
Aizaz Imtiaz AwanKeymasterHello,
It seems to be a core WordPress problem not related to our theme. Try to install Classic Widgets plugin to fix this problem for now https://wordpress.org/plugins/classic-widgets/
Best Regards
January 8, 2022 at 11:58 am #344125
horny_fungusParticipantThanks for fast reply. Can you please advice how I can trigger the issue, so I can test the solution you provided?
January 8, 2022 at 12:14 pm #344127
Aizaz Imtiaz AwanKeymasterHello,
This issue occurs when you try to modify or add new widgets under Appearance >> Widgets.
Best Regards
January 9, 2022 at 2:36 pm #344216
horny_fungusParticipantUnfortunately the issue repeated even after I installed and activated Classic Widgets plugin.
January 10, 2022 at 6:36 am #344272
Aizaz Imtiaz AwanKeymasterHello,
Please deactivate all the third party plugins and provide the login details of the website.
Best Regards
January 10, 2022 at 10:04 am #344304
horny_fungusParticipantUnfortunately this is impossible as this is live site and it won’t work as intended with plugins deactivated.
BTW the error was already reported here – https://xtemos.com/forums/topic/need-help-to-fix-one-issue/January 10, 2022 at 11:55 am #344333
Aizaz Imtiaz AwanKeymasterHello,
Sorry for the misunderstanding. Some of the Errors you mentioned were from the widget area. Which are fixed after installing the classic widgets plugin.
Therefore the other error would be fixed in the nearest update as mentioned in the other topic you attached.
Best Regards
January 14, 2022 at 3:07 pm #345431
horny_fungusParticipantThere are several more related warnings (I suppose all these are PHP 8 specific).
Warning: foreach() argument must be of type array|object, null given in /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php on line 538
Warning: Undefined array key "fields" in /wp-content/themes/woodmart/inc/widgets/wph-widget-class.php on line 538
January 17, 2022 at 8:03 am #345813
Artem TemosKeymasterHello,
Thank you for your report. We will fix these errors in our next theme update.
Kind Regards
-
AuthorPosts
- You must be logged in to create new topics. Login / Register