Your code is correct but just you have called wrong capability in
add_submenu_page.You just need to replace this
'manage_options'instead of'manage-options'. And please check it. It’s works.
Reference: https://developer.wordpress.org/reference/functions/add_submenu_page/
Related Posts:
- How to Add a Third Level Sub Menu to the WordPress Admin Menu
- Creating a WordPress admin page without a menu for a plugin
- Plugin development: how to create a form and get custom data?
- Master menu item for multiple plugins?
- wp_verify_nonce() why return false?
- Detecting when a custom taxonomy has been changed and display alert?
- Hide Theme options and Customize Admin menu
- White page on custom plugin option submit
- Suggestions on Approach to New Plugin I’m Stuck On
- creating a plug in that would tap into save/update action of posts [closed]
- Why WP_Screeen doesn’t show all options with admin_body_class
- How do I add an options page at the bottom of the list?
- How to remove a CPT Menu from the Root Admin only
- Admin menu hilighting wrong item for CPT
- How to add submenu to WordPress plugin in the same Directory of main Plugin?
- How can I pass value to function in add_menu_page?
- Submitting form to admin-post.php WordPress
- What is difference between get_bloginfo(‘url’) and get_site_url()?
- Custom media upload content for inserting custom post shortcode
- Making my plugin multi-site compatible
- dbDelta only creates the last table
- How can I make it so the Add New Post page has Visibility set to Private by default?
- Checking if an attribute exists in a shortcode
- How to create a WordPress plugin for another wordpress plugin?
- Admin menu as submenu from another plugin
- How to add option box in “Edit Post” plugin API?
- Sync my svn repositories
- Override plugin localization
- When do I need to use esc_attr when using WordPress internal functions
- use WordPress theme / plugin editor in my plugin
- What is the best way to output plugin result in certain url
- Where should my plugin POST to?
- Security error WP 4.0 + WP phpBB Bridge [closed]
- WordPress adding tags into plugin content
- Plugin Development: WordPress processes twice on post update. How to skip process on the first?
- WordPress widget / plugin….fields not appearing in my widget
- Execute a function using ajax
- This doesnt work for Plugin get_template_directory_uri()
- What is $tab in `install_plugins_{$tab}` hook?
- Is it possible to upload a template file to a directory that can be used by all themes?
- WordPress hook for visiting a post
- Fatal error: Class not found in
- How do I use WordPress PHP functions in my Javascript code?
- Get all options saved by another plugin
- Showing Notifications While Activating Plugin
- Workflow and best practice for documentation [closed]
- Creating a modal dialog without jQuery
- Language Translation is not working?
- What user roles should have wp_unique_post_slug_is_bad_flat_slug filter applied?
- How to get the permalink of a page when loading my plugin
- How can I create a simple interface for my WP plugin?
- Where to put my global functions?
- Passing $this->get_field_name() to javascript
- Hidden Custom Post Type
- Is there a way to programmatically enable a plugin?
- add_action in functions.php, do_action in plugin?
- Ajax gives 400 error
- Adding Attachment Display Settings in custom media frame
- How to include code into functions.php file via a plugin
- Read text defined under __()
- WordPress Plugin Page is Loading in Admin Content Container Instead of Separate Page
- Serialize data for wp options
- How can I get WordPress to save comments in markdown format?
- Is Wrapping intval() Around esc_attr() Redundant for Escaping Input?
- React JSX in WordPress Plugin Development
- My plugin wants to update another plugin
- Simple ajax call not working in wordpress plugin
- Plugin Options Not Saving to Database in WP 4.5
- How to save post change url youtube link?
- __callStatic method handler passed to add_action causes bug in PHP
- how to disable blockrenderAppender inside all Innerblocks?
- Redirection of users away from wp-admin (but not administrators)
- New databes tables with – WooCommerce – for developers [closed]
- Plugin-generated pages use Not Found or Pages Archive templates?
- Change commission_status paid when withdraw_status vendor is completed
- Using SVN to upload plugin created with gutenberg blocks
- 306 MB of wp_options occupied by WordPress SEO Plugin, is that normal? [closed]
- WordPress Plugin [closed]
- Perform internal redirect in WordPress?
- How to prevent plugins from loading jQuery
- How do I set register_meta for a specific CPT?
- How to Enfroce Domain Licensing Limits? [closed]
- How can I save the selected page in the dropdown after anyone clicks on Save Changes?
- Update Content for a Custom Block Toolbar Button
- How can I save the selected page in the dropdown after anyone clicks on Save Changes?
- Wrong block appender button showing
- Uncaught Error: Cannot use object of type stdClass while showing the list using WP_List_Table
- How to give specific class name to category in wordpress with code snippets
- admin_enqueue_scripts using hook_suffix vs GET page
- WordPress Throwing Deprecated Errors on its own Files
- plugin doesn’t retrieve data from database
- Display Any Field fromAdmin Panel in Frontend via Shortcode?
- WordPress.Security.NonceVerification.Recommended
- BBPress Customization with Custom Plugin
- How can we extent core/group or cover block?
- Need to add custom cart item data
- I want to create a search option for CPT using plugin. The search options should search for categories and tags
- plugin development code standard not matching for SQL query
- Ajax response from Media Selection does not update ALL information more than once
- Custom Gutenberg blocks not showing in WP editor