add_section('alternative_upgrade_links', array(
'title' => __('About Alternative', 'alternative'),
'priority' => 2,
));
$wp_customize->add_setting( 'alternative_upgrade_links', array(
'default' => false,
'capability' => 'edit_theme_options',
'sanitize_callback' => 'wp_filter_nohtml_kses',
));
$wp_customize->add_control(
new Alternative_Customize_upgrade(
$wp_customize,
'alternative_upgrade_links',
array(
'section' => 'alternative_upgrade_links',
'settings' => 'alternative_upgrade_links',
)
)
);
}
}
add_action( 'customize_register', 'alternative_customize_register' );
/************ Renaming Panel and Section Customizer name to Alternative *******************/
add_action( 'customize_register', 'alternative_customize_register_wordpress_default' );
function alternative_customize_register_wordpress_default( $wp_customize ) {
$wp_customize->add_panel( 'edge_wordpress_default_panel', array(
'priority' => 5,
'capability' => 'edit_theme_options',
'theme_supports' => '',
'title' => __( 'Alternative WordPress Settings', 'alternative' ),
'description' => '',
) );
}
add_action( 'customize_register', 'alternative_customize_register_options', 20 );
function alternative_customize_register_options( $wp_customize ) {
$wp_customize->add_panel( 'edge_options_panel', array(
'priority' => 6,
'capability' => 'edit_theme_options',
'theme_supports' => '',
'title' => __( 'Alternative Theme Options', 'alternative' ),
'description' => '',
) );
}
add_action( 'customize_register', 'alternative_customize_register_featuredcontent' );
function alternative_customize_register_featuredcontent( $wp_customize ) {
$wp_customize->add_panel( 'edge_featuredcontent_panel', array(
'priority' => 7,
'capability' => 'edit_theme_options',
'theme_supports' => '',
'title' => __( 'Alternative Slider Options', 'alternative' ),
'description' => '',
) );
}
add_action( 'customize_register', 'alternative_customize_register_widgets' );
function alternative_customize_register_widgets( $wp_customize ) {
$wp_customize->add_panel( 'widgets', array(
'priority' => 8,
'capability' => 'edit_theme_options',
'theme_supports' => '',
'title' => __( 'Alternative Widgets', 'alternative' ),
'description' => '',
) );
}
add_action( 'customize_register', 'alternative_customize_register_colors' );
function alternative_customize_register_colors( $wp_customize ) {
$wp_customize->add_panel( 'colors', array(
'priority' => 9,
'capability' => 'edit_theme_options',
'theme_supports' => '',
'title' => __( 'Alternative Colors', 'alternative' ),
'description' => '',
) );
}
if(!class_exists('Edge_Plus_Features')){
// Add Upgrade to Plus Button.
require_once( trailingslashit( get_stylesheet_directory() ) . 'inc/upgrade-plus/class-customize.php' );
}