codesnippetspro/code-snippets

Having the option to moving Snippets menu further down in the WP menu.

Closed this issue · 4 comments

Currently the Snippets plugin is seen in the left WP menu here:

Screenshot 2022-09-27 at 12 01 52

It would be nice to add a setting to the Settings screen with the option of where to place the Snippets menu.
Perhaps something like this:

Change the location of Snippets menu in your WordPress menu: default 10 (just below the Plugins menu item).
Adjusting the number to higher or lower will then move the Snippets menu to a new location.
As many times I just want to keep plugin menus on the bottom below WP Settings.

Good idea! This could definitely be a feature, though I am not sure whether it needs to be an option on the Settings page or just a filter hook.

How would a filter hook work?

You would add a snippet with code similar to this:

add_filter( 'code_snippets/admin/menu_position', function () { return 20; } );

Will be present in the next plugin release.

I've also written an FAQ article to explain how to use this: https://help.codesnippets.pro/article/61-how-can-i-change-the-location-of-the-snippets-admin-menu