Inventory_Presser_Options::add_options_page()

add_options_page


Description Description

Adds an options page to the dashboard to hold all this plugin's settings.


Top ↑

Return Return

(void)


Top ↑

Source Source

File: includes/class-dealership-options.php

	public function add_options_page()
	{
		if ( post_type_exists( INVP::POST_TYPE ) )
		{
			add_submenu_page('edit.php?post_type=' . INVP::POST_TYPE,
				__( 'Options', 'inventory-presser' ), // page_title
				__( 'Options', 'inventory-presser' ), // menu_title
				'manage_options', // capability
				'dealership-options', // menu_slug
				array( $this, 'options_page_content' ) // function
			);
			return;
		}

		add_options_page(
			__( 'Inventory Presser', 'inventory-presser' ), // page_title
			__( 'Inventory Presser', 'inventory-presser' ), // menu_title
			'manage_options', // capability
			'dealership-options', // menu_slug
			array( $this, 'options_page_content' ) // function
		);
	}