Tips on Customizing Marketing Toolkit by OptinMonster – Popups, Email Optin Forms & Newsletter Subscribers

How to Hide OptinMonster API Admin Menus

function plt_hide_optinmonster_menus() {
	//Hide the "OptinMonster" menu.
	//Hide the "OptinMonster → Authorization" menu.
	remove_submenu_page('optin-monster-api-settings', 'optin-monster-api-settings');
	//Hide the "OptinMonster → Social Proof Widget" menu.
	remove_submenu_page('optin-monster-api-settings', 'optin-monster-trustpulse');

add_action('admin_menu', 'plt_hide_optinmonster_menus', 11);

Where do I put this code?

How to Hide the "Please Connect OptinMonster" Dashboard Widget

function plt_hide_optinmonster_dashboard_widgets() {
	$screen = get_current_screen();
	if ( !$screen ) {

	//Remove the "Please Connect OptinMonster" widget.
	remove_meta_box('optin_monster_db_widget', 'dashboard', 'normal');

add_action('wp_dashboard_setup', 'plt_hide_optinmonster_dashboard_widgets', 20);