Title: [Plugin: Widget Logic] Error First argument should be an array
Last modified: August 20, 2016

---

# [Plugin: Widget Logic] Error First argument should be an array

 *  [lorddonk](https://wordpress.org/support/users/lorddonk/)
 * (@lorddonk)
 * [14 years, 2 months ago](https://wordpress.org/support/topic/plugin-widget-logic-error-first-argument-should-be-an-array/)
 * Warning: array_push() [function.array-push]: First argument should be an array
   in […]/wp-content/plugins/widget-logic/widget_logic.php on line 67
 * I think this is because I have two “widget” modifying plugins. Your widget logic
   program (which is amazing!) and another plugin which lets me add a class to all
   my widgets
 * [http://wordpress.org/extend/plugins/widget-classes/](http://wordpress.org/extend/plugins/widget-classes/)
 * Can this problem be fixed?
 * [http://wordpress.org/extend/plugins/widget-logic/](http://wordpress.org/extend/plugins/widget-logic/)

Viewing 1 replies (of 1 total)

 *  [alanft](https://wordpress.org/support/users/alanft/)
 * (@alanft)
 * [14 years, 2 months ago](https://wordpress.org/support/topic/plugin-widget-logic-error-first-argument-should-be-an-array/#post-2663087)
 * W Logic and W classes use different, but related, ways of intercepting the control
   on the widget’s config page which I think are mutually incompatible.
 * WL adds the ID to the widget’s params, WC replaces the params with just the ID,
   saving the params elsewhere. You could try expanding line 67 of WL to something
   like
 *     ```
       if (is_array($wp_registered_widget_controls[$id]['params']))
       	array_push($wp_registered_widget_controls[$id]['params'],$id);
       else if (isset($wp_registered_widget_controls[$id]['_params']))
       	array_push($wp_registered_widget_controls[$id]['_params'],$id);
       ```
   
 * but i’ve not tried it as i’m way too lazy at the moment, sorry.
 * All respect to the writer and users of WC, I don’t see what WC is for as widgets
   already have CSS classes, and blocking different classes together in the CSS 
   code seems like less coding overhead.

Viewing 1 replies (of 1 total)

The topic ‘[Plugin: Widget Logic] Error First argument should be an array’ is closed
to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/widget-logic_c8dde5.svg)
 * [Widget Logic](https://wordpress.org/plugins/widget-logic/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/widget-logic/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/widget-logic/)
 * [Active Topics](https://wordpress.org/support/plugin/widget-logic/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/widget-logic/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/widget-logic/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [alanft](https://wordpress.org/support/users/alanft/)
 * Last activity: [14 years, 2 months ago](https://wordpress.org/support/topic/plugin-widget-logic-error-first-argument-should-be-an-array/#post-2663087)
 * Status: not resolved