Add custom WordPress admin page with pretty url via code

Question

WordPress add_menu_page and add_submenu_page support adding custom page. The page created have url with a slug similar to wp-admin/admin.php?page=our-custom-page

How can create a admin page which will have a slug similar to wp-admin/admin.php/our-custom-page

I also want the pages to support inner routing similar to wp-admin/admin.php/our-custom-page

I know it can be done with server settings, I’m looking for way to created this from a theme/plugin.

The main goal is to create the custom admin page without any “?” of url params. The route is less important is long that it’s inside wp-admin/

0
, , , , BenB 3 years 2020-04-05T20:51:03-05:00 0 Answers 92 views 0

Leave an answer

Browse
Browse