Problem width wp_customize
-
Hi I have used a theme customizer in my function file but when I try to insert the results in the template it doesn’t shows.
There is something wrong in the code ?// Home Customizer add_action('customize_register', 'marine_home_customizer' ); function marine_home_customizer($wp_customize) { $wp_customize->add_section('themename_color_scheme', array( 'title' => __('Home', 'marine'), 'description' => '', 'priority' => 120, )); // ============================= // = Title = // ============================= $wp_customize->add_setting('themename_theme_options[text_test]', array( 'default' => 'Titolo 2', 'capability' => 'edit_theme_options', 'type' => 'theme_mod', )); $wp_customize->add_control('themename_text_test', array( 'label' => __('Titolo', 'marine'), 'section' => 'themename_color_scheme', 'settings' => 'themename_theme_options[text_test]', )); }Template file
<?php echo get_theme_mod('text_test'); ?>
The topic ‘Problem width wp_customize’ is closed to new replies.