'', 'favicon' => '', 'link_color' => '700000', 'custom_css' => '', 'analytics' => '' ); if ( is_admin() ) : function mnk_register_settings() { // Register settings and call sanitation functions register_setting( 'mnk_theme_options', 'mnk_options', 'mnk_validate_options' ); } add_action( 'admin_init', 'mnk_register_settings' ); function mnk_theme_options() { // Add theme options page to the addmin menu add_theme_page( 'Theme Options', 'Theme Options', 'edit_theme_options', 'theme_options', 'mnk_theme_options_page' ); } add_action( 'admin_menu', 'mnk_theme_options' ); // Function to generate options page function mnk_theme_options_page() { global $mnk_options; if ( ! isset( $_REQUEST['updated'] ) ) $_REQUEST['updated'] = false; // This checks whether the form has just been submitted. ?>
" . get_current_theme() . __( ' Theme Options' ) . ""; // This shows the page's name and an icon if one has been provided ?>