*/ class Amp_WP_System_Status { /** * Initialize the class and set its properties. * * @since 1.4.0 * @param string $plugin_name The name of this plugin. * @param string $version The version of this plugin. */ public function __construct() { // Action - Add System Status Menu add_action( 'admin_menu', array($this, 'admin_menu'), 50 ); } /** * Add System Status Menu Under AMP WP Admin Menu. * * @since 1.4.0 */ public function admin_menu() { add_submenu_page( 'amp-wp-welcome', // string $parent_slug 'System Status', // string $page_title 'System Status', // string $menu_title 'manage_options', // string $capability 'amp-wp-system-status', // string $menu_slug array( $this, 'amp_wp_system_status' ) // callable $function ); } /** * Add System Status Page. * * @Since 1.4.0 */ public function amp_wp_system_status() { $page = filter_input(INPUT_GET, 'page'); require_once AMPWP_TEMPLATE_DIR_PATH . 'admin/partials/amp-wp-admin-system-status.php'; } } new Amp_WP_System_Status();