This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

sayaamiruladli51935
sayaamiruladli51935

How to properly do this?

Flynsarmy
Flynsarmy

If you want to remove it this is how I do it. Add this to your plugin registration file:

public function boot()
{
    Event::listen('backend.menu.extendItems', function($navigationManager) {
        $navigationManager->removeMainMenuItem('October.Backend', 'media');
    });
}
sayaamiruladli51935
sayaamiruladli51935

Flynsarmy said:

If you want to remove it this is how I do it. Add this to your plugin registration file:

public function boot() { Event::listen('backend.menu.extendItems', function($navigationManager) { $navigationManager->removeMainMenuItem('October.Backend', 'media'); }); }

tq man!!

sayaamiruladli51935
sayaamiruladli51935

Here is the snippet to move your media tab nav to settings:

    public function boot()
    {
        Event::listen('backend.menu.extendItems', function ($navigationManager) {
            $navigationManager->removeMainMenuItem('October.Backend', 'media');
        });
    }

    public function registerSettings()
    {
        return [
            'media' => [
                'label'       => 'Media',
                'description' => 'Manage media.',
                'category'    => 'Media',
                'icon'        => 'icon-file-image-o',
                'url'         => Backend::url('backend/media'),
                'order'       => 500,
                'keywords'    => 'media manager'
            ]
        ];
    }

1-4 of 4

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.