Created
September 26, 2018 16:36
-
-
Save sabbir1991/91251b07f227febafa945d0cfe0abac2 to your computer and use it in GitHub Desktop.
Revisions
-
sabbir1991 renamed this gist
Sep 26, 2018 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
sabbir1991 created this gist
Sep 26, 2018 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,31 @@ <?php add_action( 'admin_menu', 'prefix_admin_menu' ); function prefix_admin_menu() { global $submenu; add_menu_page( __( 'Project Manager', 'text-domain' ), __( 'Project Manager', 'text-domain' ), 'manage_options', 'awesome-pm', 'pm_dashboard_cb' ); $submenu[ 'awesome-pm' ][] = array( __( 'Project', 'text-domain' ), 'manage_options', 'admin.php?page=awesome-pm#/' ); $submenu[ 'awesome-pm' ][] = array( __( 'Message', 'text-domain' ), 'manage_options', 'admin.php?page=awesome-pm#/message' ); $submenu[ 'awesome-pm' ][] = array( __( 'Settings', 'text-domain' ), 'manage_options', 'admin.php?page=awesome-pm#/settings' ); } // For line number 8 callback function. where main single page div loaded function pm_dashboard_cb() { ?> <div class="wrap"> <div id="vue-app"><div> </div> <?php } =============================================================== Output will be: Project Manager ----> Main menu : cause line no- 8 - Project ---> Sub menu: cause line no- 10 - Message ---> Sub menu: cause line no- 11 - Settings -----> Sub menu: cause line no- 12