Fügen Sie der Adminseite ein Tab-Menü hinzu

Ich bin sehr neu in WordPress und hier möchte ich eine Admin-Seite mit Tabs wie im Bild gezeigt erstellen

Admin-Bereiche mit Tabs

Wie kann ich eine solche Seite mit diesen Tabs erstellen?

Solutions Collecting From Web of "Fügen Sie der Adminseite ein Tab-Menü hinzu"

wenn Sie diese Methode nicht mögen. vielleicht möchtest du den folgenden Code:
Bildbeschreibung hier eingeben Sie können versuchen, den folgenden Code in Ihre Datei functions.php einzufügen.

// Theme options /* get options & set default options */ if( !function_exists('share3h_theme_get_options') ) : function share3h_theme_get_options($option){ $share3h_theme_options = get_option('share3h_theme_options'); if( !$share3h_theme_options || array_key_exists($option, $share3h_theme_options) ) : $share3h_theme_default_options = array( 's3h_title' => '0', 's3h_keywords' => '0', 's3h_description' => '0', 's3h_headerlogo' => '0', 's3h_footerlogo' => '0', 's3h_qrcode' => '0', 's3h_banner_1' => '0', 's3h_banner_2' => '0', 's3h_banner_3' => '0', 's3h_banner_4' => '0', 's3h_banner_s1' => '0', 's3h_banner_s2' => '0', 's3h_banner_s3' => '0', 's3h_banner_s4' => '0', 's3h_copyright' => '0', 's3h_code_1' => '0', 's3h_code_2' => '0', ); add_option('share3h_theme_options', $share3h_theme_default_options, ''); $result = $share3h_theme_options[$option]; else: $result = $share3h_theme_options[$option]; endif; return $result; } endif; /* entering form data */ if( !function_exists('share3h_theme_backend') ) : function share3h_theme_backend(){ ?> 

< ?php echo __('Theme Setup', LANGUAGE_ZONE); ?>

< ?php $active_tab = isset($_GET['tab']) ? $_GET['tab'] : 'general'; if(isset($_GET['tab'])) $active_tab = $_GET['tab']; ?>
< ?php if($active_tab == 'general') { ?>

< ?php _e('General Settings', LANGUAGE_ZONE); ?>

< ?php echo __('SEO use.',LANGUAGE_ZONE); ?>

< ?php echo __('SEO use.',LANGUAGE_ZONE); ?>

< ?php echo __('SEO use.',LANGUAGE_ZONE); ?>

< ?php } if($active_tab == 'banner') { ?>

< ?php _e('Banner Settings', LANGUAGE_ZONE); ?>

< ?php echo __('Image', LANGUAGE_ZONE); ?>

< ?php echo __('Image', LANGUAGE_ZONE); ?>

< ?php echo __('Image', LANGUAGE_ZONE); ?>

< ?php echo __('Image', LANGUAGE_ZONE); ?>

< ?php echo __('Image', LANGUAGE_ZONE); ?>

< ?php echo __('Image', LANGUAGE_ZONE); ?>

< ?php echo __('Image', LANGUAGE_ZONE); ?>

< ?php echo __('Image', LANGUAGE_ZONE); ?>

< ?php } if($active_tab == 'other') { ?>

< ?php _e('Other Settings', LANGUAGE_ZONE); ?>

< ?php echo __('This can be used share code or other code, it will be loaded before end of body tag.',LANGUAGE_ZONE); ?>

< ?php echo __('This can be used share code or other code, it will be loaded before end of body tag.',LANGUAGE_ZONE); ?>

< ?php } ?>

< ?php } endif; /* submit form data */ if( !function_exists('share3h_theme_form')) : function share3h_theme_form(){ //array_key_exists('submit', $_POST) ? $submit = $_POST['submit']:$submit = NULL; //isset($_POST['submit'])? $submit=$_POST['submit'] : $submit = NULL; if($_POST['submit']): $share3h_theme_new_options=array(); $share3h_theme_options=get_option('share3h_theme_options'); foreach($share3h_theme_options as $key=>$value){ if($_POST[$key]==''){ $share3h_theme_new_options[$key]=$value; }else{ $share3h_theme_new_options[$key]=$_POST[$key]; } } update_option('share3h_theme_options', $share3h_theme_new_options); endif; echo share3h_theme_backend(); } endif; /* set menu */ if( !function_exists('share3h_theme_menu') ) : function share3h_theme_menu(){ add_options_page(__('Theme setup', LANGUAGE_ZONE), __('Theme setup', LANGUAGE_ZONE), 'read', 'theme_option', 'share3h_theme_form'); } endif; add_action('admin_menu', 'share3h_theme_menu');

Sie können das OptionTree-Plugin https://wordpress.org/plugins/option-tree/ verwenden
Es kann auch im Themenmodus gearbeitet werden. Bildbeschreibung hier eingeben