Louis W
Louis W

Reputation: 3252

Hide admin menu items

I have seen quite a bit of posts about hiding menu items in admin, the method I chose was to create a custom module and disable it through there - which seemed like the most elegant way of doing this. But I can't quite seem to get it to work. Here is what I did:

File: app/etc/modules/LDW_All.xml

<?xml version="1.0"?>
<config>
    <modules>
        <LDW_AdminMenu>
            <active>true</active>
            <codePool>local</codePool>
        </LDW_AdminMenu>
    </modules>
</config> 

File: app/code/local/LDW/AdminMenu/etc/adminhtml.xml

<?xml version="1.0" encoding="utf-8"?>
<config>
    <modules>
        <LDW_AdminMenu>
            <version>0.1.0</version>
        </LDW_AdminMenu>
    </modules>
    <adminhtml>
        <menu>
            <mobile>
                <depends><module>HideMe</module></depends>
            </mobile>
        </menu>
    </adminhtml>
</config>

Source: http://www.bubblecode.net/en/2012/01/21/magento-how-to-hide-menu-items-of-admin-panel/

Upvotes: 1

Views: 3261

Answers (1)

MagePal Extensions
MagePal Extensions

Reputation: 17656

Take a look @ Magento remove "Promo" Item

Since you put your code in the community folder and not local (code pool)

Your need to change your codePool in app/etc/modules/ from

<codePool>local</codePool>

To

<codePool>community</codePool>

Also rename your xml file

app/etc/modules/LDW.xml

to

app/etc/modules/LDW_AdminMenu.xml (or LDW_All.xml)

In config.xml

<config>
    <modules>
        <LDW_AdminMenu>
            <version>0.1.0</version>
        </LDW_AdminMenu>
    </modules>
    <adminhtml>
        <menu>
            <xmlconnect>
                <disabled>1</disabled>
            </xmlconnect>
        </menu>
    </adminhtml>
</config>

Upvotes: 2

Related Questions