Theme customization error
-
I wrote this code inside my functions.php
function sleepy_customizer_register($wp_customize) { $wp_customize->add_section('sleepy_colors', array ( 'title'=> __('Colors','sleepy'), 'description'=> 'Modify the theme colors.' )); $wp_customize->add_setting('first_palette', array ( 'default'=>'#3F7696' )); $wp_customize->add_control(new WP_Customize_Color_Control('$wp_customize', 'first_palette', array ( 'label'=> __('Change the first pallete of colors.','sleepy'), 'section'=>'sleepy_colors', 'setting'=>'first_palette' ))); } add_action('customize_register','sleepy_customizer_register')
and this error ocurs :
Fatal error: Call to a member function get_setting() on a non-object in D:\xampp\htdocs\wp-includes\class-wp-customize-control.php on line 109
If anyone can help me i would be thankful 🙂
- The topic ‘Theme customization error’ is closed to new replies.