Title: Hide leaflet-shortcode-helper
Last modified: July 24, 2023

---

# Hide leaflet-shortcode-helper

 *  [simonc17](https://wordpress.org/support/users/simonc17/)
 * (@simonc17)
 * [2 years, 10 months ago](https://wordpress.org/support/topic/hide-leaflet-shortcode-helper/)
 * Hi,
 * I’m trying to hide various admin menu items from wordpress authors using a bit
   of php but I can’t hide leaflet-shortcode-helper. I have tried:
 * remove_menu_page( ‘leaflet-shortcode-helper’ ); remove_submenu_page( ‘leaflet-
   map’, ‘leaflet-shortcode-helper’ );
 * but these don’t work. Can someone give me the right bit of php to do it?
 * Many thanks.

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Contributor [hupe13](https://wordpress.org/support/users/hupe13/)
 * (@hupe13)
 * [2 years, 10 months ago](https://wordpress.org/support/topic/hide-leaflet-shortcode-helper/#post-16919496)
 * Adapted from [https://developer.wordpress.org/reference/functions/remove_submenu_page/#comment-711](https://developer.wordpress.org/reference/functions/remove_submenu_page/#comment-711):
 *     ```wp-block-code
       /**
        * Remove the Leaflet Map Shortcode Helper Page
        */
       function leafext_remove_leaflet_helper() {
       	$page = remove_submenu_page( 'leaflet-map', 'leaflet-shortcode-helper' );
       }
       add_action( 'admin_menu', 'leafext_remove_leaflet_helper', 999 );
       ```
   
 *  Thread Starter [simonc17](https://wordpress.org/support/users/simonc17/)
 * (@simonc17)
 * [2 years, 10 months ago](https://wordpress.org/support/topic/hide-leaflet-shortcode-helper/#post-16923759)
 * Hi hupe13,
 * Thanks for this but unfortunately it doesn’t work.
 * I pasted your code in and the helper still displays after logging back in.
 * Thanks, Simon
 *  Plugin Contributor [hupe13](https://wordpress.org/support/users/hupe13/)
 * (@hupe13)
 * [2 years, 10 months ago](https://wordpress.org/support/topic/hide-leaflet-shortcode-helper/#post-16923852)
 * I don’t know. It works on my test site.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Hide leaflet-shortcode-helper’ is closed to new replies.

 * ![](https://ps.w.org/leaflet-map/assets/icon-256x256.png?rev=1693083)
 * [Leaflet Map](https://wordpress.org/plugins/leaflet-map/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/leaflet-map/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/leaflet-map/)
 * [Active Topics](https://wordpress.org/support/plugin/leaflet-map/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/leaflet-map/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/leaflet-map/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [hupe13](https://wordpress.org/support/users/hupe13/)
 * Last activity: [2 years, 10 months ago](https://wordpress.org/support/topic/hide-leaflet-shortcode-helper/#post-16923852)
 * Status: not resolved