Title: Warning: Array to string conversion
Last modified: May 15, 2023

---

# Warning: Array to string conversion

 *  [joxyzan](https://wordpress.org/support/users/joxyzhan/)
 * (@joxyzhan)
 * [3 years ago](https://wordpress.org/support/topic/warning-array-to-string-conversion-9/)
 * Howdy!
 * Great plugin!
 * But: After installing another popular plugin (Da Reactions) two warnings show
   at the top of **every** WordPress backend page… which is quite disturbing… (The
   plugins seems to work fine though.)
 * **#1**:
 * > **Warning:** Array to string conversion in **/…/wp-content/plugins/admin-menu-
   > editor/includes/menu-item.php** on line **54**
 * Line 54:
 *     ```wp-block-code
       'page_title'   => (isset($item[3]) ? strval($item[3]) : ''),
       ```
   
 * **#2**:
 * > **Warning:** Undefined array key “page” in **/…/wp-content/plugins/da-reactions/
   > classes/DaReactions/Admin.php** on **line 310**
 * Line 310:
 *     ```wp-block-code
       'screen_name'   => filter_var( $_GET["page"], 
       ```
   
 * I’m not capable to see the problem… But maybe the warnings are related? Could
   you maybe tell me how to fix it?

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Janis Elsts](https://wordpress.org/support/users/whiteshadow/)
 * (@whiteshadow)
 * [3 years ago](https://wordpress.org/support/topic/warning-array-to-string-conversion-9/#post-16738172)
 * The first warning happens because of this: when Da Reactions creates the “Reactions-
   > Help” menu item, it sets the page title to an array instead of a string (in
   other words, text). The title should always be text. Admin Menu Editor then tries
   to convert the title to a string and triggers the warning in the process.
 * This is relatively harmless (the menu still works), but I’ll add a small workaround
   in the next plugin to avoid triggering warnings like this when other plugins 
   provide invalid page titles for menu items.
 * The second warning seems unrelated. Based on some quick testing, that warning
   shows up even when Admin Menu Editor is not activated, so it’s probably not related
   to this plugin.
 *  Thread Starter [joxyzan](https://wordpress.org/support/users/joxyzhan/)
 * (@joxyzhan)
 * [3 years ago](https://wordpress.org/support/topic/warning-array-to-string-conversion-9/#post-16738202)
 * Thank your for a very quick and clear response! 🙏
 * I’ll wait for your update to get rid of the first warning and contact Da Reactions
   about the second warning.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Warning: Array to string conversion’ is closed to new replies.

 * ![](https://ps.w.org/admin-menu-editor/assets/icon-128x128.png?rev=1418604)
 * [Admin Menu Editor](https://wordpress.org/plugins/admin-menu-editor/)
 * [Support Threads](https://wordpress.org/support/plugin/admin-menu-editor/)
 * [Active Topics](https://wordpress.org/support/plugin/admin-menu-editor/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/admin-menu-editor/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/admin-menu-editor/reviews/)

## Tags

 * [conversion](https://wordpress.org/support/topic-tag/conversion/)
 * [php](https://wordpress.org/support/topic-tag/php/)
 * [warning](https://wordpress.org/support/topic-tag/warning/)

 * 2 replies
 * 2 participants
 * Last reply from: [joxyzan](https://wordpress.org/support/users/joxyzhan/)
 * Last activity: [3 years ago](https://wordpress.org/support/topic/warning-array-to-string-conversion-9/#post-16738202)
 * Status: not resolved