Under Pages menu in Wordpress Admin page, I acquired this layout:


  • Edit (url: edit-pages.php)
  • Add New (url: page-new.php)
  • Special Pages (url: edit-pages.php?special-pages=true)

as you can tell, I have added a brand new submenu item known as Special Pages that is virtually a hyperlink to to Edit page with custom filter. Because Wordpress use file title to recognize and highlight the submenu item, so whenever I click Special Pages, the Edit submenu item is chosen. Can there be anyway to pressure Wordpress to choose Special Pages food selection rather?


Solution: use $submenu_file variable

$submenu_file = "edit-pages.php?special-pages=true"