Admin Menu Extra Items and Errors Not quite sure how to explain this, but I will go through what I did, and when the errors started happening.

I have enabled the default taxonomy view in Views, changed it to fields, and added a grouped filter.

After saving, I see the error "Warning: htmlspecialchars() expects parameter 1 to be string, array given in check_plain() (line 1583 .../html/includes/bootstrap.inc)." AND suddenly the admin menu has loads of new items in it?



I read up on it, but cant see any fixes, so try disabling and re-enabling the taxonomy view, and also admin menu.

Now the error message has gone, everything works fine, but I am left with all of these extra menu items in the admin menu.

I have logged in as other lower level users, and their admin menus are fine, yet as the super user (with all permissions) I have about 20 or 30 menu items added to the menu before the usual entries.

I have no idea where to start looking with this. The error above seems to happen when a module passes an array through check_plain(), so it usually a module error rather than core. But in this case, it seems to be the taxonomy view that has triggered it, unless its a coincidence.

Can anyone offer guidance? 

EDIT: Also tried flushing cache. And worst comes to worse can revert to a backup 5 days ago, but will lose a fair bit of content, so want to avoid this.

EDIT: Looking phpmyadmin, I can see that all of these new menu items have indeed been added to the menu_links table, but do not appear in the structure > menus > management list.
Reverting the taxonomy view back to its original state, and then rebuilding the changes again made the errors disappear from watchdog, but the management menu and admin menu were still completely messed up.

To fix this, I installed Devel module, and the ran a SQL query to delete all menu rows added by system.

mysql&gt; delete from menu_links where module='system';


I then navigated to /devel/menu/reset 

This successfully re-built the management menu, and everything went back to normal.

Note: I also used backup and migrate to quickly clone the website onto a local server and test the changes before making the changes on the production environment.