When you save a admin/structure/menu/item/%/edit page, Menu Icons generates the CSS based on the menu-icons-css-item.tpl.php file in your theme if you have one. But when you save node/%/edit, it generates it from the one in the module folder, regardless of whether you have one in your theme. The result is that whenever you save a node with a menu link, all your custom-CSS icons disappear completely.

Comments

Lanny Heidbreder’s picture

Realized that this is because I use the admin theme for node edit pages, and the admin theme didn't have my template file in it.

Not sure what the right solution here is. Seems like something fundamentally wrong with the logic used to generate the CSS. I may come back to this later, but for now I'm going to copy my template file into my admin theme as a quick fix.

mshepherd’s picture

Nicely spotted @75th Trombone. This was driving me mad. Simple workaround, but it does suggest a problem in the logic somewhere. Cheers.

demonde’s picture

+1

fox mulder’s picture

Hi all!

I ran into this ( or something similar ) problem today. My theme overrides menu_icons_css_item.tpl.php and everything worked well, but today the menu_icons.css was regenerated from sites/all/contrib/menu_icons/menu_icons_css_item.tpl.php...

I found this issue and made some tests, but I can not reproduce the problem.

First of all: clearing all caches solved the problem for me.

I tried to create a node of node type that can provide menu link ( edit page contains menu icon settings and I filled it in ), but it did not save menu icon settings ( another problem? ) and the problem did not came out ( I'm using admin theme on node/edit pages too ).

fox mulder’s picture