Current File : /home/kelaby89/teamhachem.com/wp-content/themes/artkombat/inc/theme-config.php
<?php if ( ! defined( 'ABSPATH' ) ) { die( 'Direct access forbidden.' ); }
/**
 * Theme Configuration and custom css initializtion
 */

/*
* Adding additional TinyMCE options
*/
function artkombat_wpb_mce_buttons_2($buttons) {
    array_unshift($buttons, 'styleselect');
    return $buttons;
}
add_filter('mce_buttons_2', 'artkombat_wpb_mce_buttons_2');

function artkombat_mce_before_init_insert_formats( $init_array ) {  

    $style_formats = array(

        array(  
            'title' => esc_html__('Main Color', 'artkombat'),
            'block' => 'span',  
            'classes' => 'color-main',
            'wrapper' => true,
        ),  
        array(  
            'title' => esc_html__('Second Color', 'artkombat'),
            'block' => 'span',  
            'classes' => 'color-second',
            'wrapper' => true,
        ),
        array(  
            'title' => esc_html__('White Color', 'artkombat'),
            'block' => 'span',  
            'classes' => 'color-white',
            'wrapper' => true,   
        ),
        array(  
            'title' => esc_html__('Large Text', 'artkombat'),
            'block' => 'span',  
            'classes' => 'text-lg',
            'wrapper' => true,
        ),    
        array(  
            'title' => esc_html__('Line Height Double', 'artkombat'),
            'block' => 'span',  
            'classes' => 'line-height-2',
            'wrapper' => true,
        ),         
        array(  
            'title' => 'List Checkbox',
            'selector' => 'ul',
            'classes' => 'check',
        ),          
        array(  
            'title' => 'List Plus',
            'selector' => 'ul',
            'classes' => 'ltx-plus',
        ),          

    );  
    $init_array['style_formats'] = json_encode( $style_formats );  
     
    return $init_array;  
} 
add_filter( 'tiny_mce_before_init', 'artkombat_mce_before_init_insert_formats' ); 


/**
 * Config used for lt-ext plugin to set Visual Composer configuration
 */
add_filter( 'ltx_get_vc_config', 'artkombat_vc_config', 10, 1 );
function artkombat_vc_config( $value ) {

    return array(
    	'sections'	=>	array(
			esc_html__("Displaced floating section", 'artkombat') 		=> "displaced-top",			
			esc_html__("Gradient Col", 'artkombat') 		=> "ltx-gradient-col",			
			esc_html__("Homepage Form", 'artkombat') 		=> "ltx-homepage-form",			
			esc_html__("Video Section", 'artkombat') 		=> "ltx-section-video",			
			esc_html__("Discount Section", 'artkombat') 		=> "ltx-discount",			
		),
		'background' => array(
			esc_html__( "Main Color", 'artkombat' ) => "theme_color",
			esc_html__( "Second Color", 'artkombat' ) => "second",			
			esc_html__( "Gray", 'artkombat' ) => "gray",
			esc_html__( "White", 'artkombat' ) => "white",
			esc_html__( "Black", 'artkombat' ) => "black",			
		),
		'overlay'	=> array(
			esc_html__( "Black Overlay (50%)", 'artkombat' ) => "black",
			esc_html__( "Dark Overlay (30%)", 'artkombat' ) => "dark",
			esc_html__( "Extra Black (90%)", 'artkombat' ) => "xblack",
			esc_html__( "True Black Overlay", 'artkombat' ) => "true-black",
		),
	);
}


/**
 * Register widget areas.
 *
 */
function artkombat_action_theme_widgets_init() {

	register_sidebar( array(
		'name'          => esc_html__( 'Sidebar Default', 'artkombat' ),
		'id'            => 'sidebar-1',
		'description'   => esc_html__( 'Displayed in the right/left section of the site.', 'artkombat' ),
		'before_widget' => '<aside id="%1$s" class="widget %2$s">',
		'after_widget'  => '</aside>',
		'before_title'  => '<h3 class="header-widget">',
		'after_title'   => '</h3>',
	) );

	register_sidebar( array(
		'name'          => esc_html__( 'Sidebar WooCommerce', 'artkombat' ),
		'id'            => 'sidebar-wc',
		'description'   => esc_html__( 'Displayed in the right/left section of the site.', 'artkombat' ),
		'before_widget' => '<aside id="%1$s" class="widget %2$s">',
		'after_widget'  => '</aside>',
		'before_title'  => '<h3 class="header-widget">',
		'after_title'   => '</h3>',
	) );

	register_sidebar( array(
		'name'          => esc_html__( 'Footer 1', 'artkombat' ),
		'id'            => 'footer-1',
		'description'   => esc_html__( 'Displayed in the footer section of the site.', 'artkombat' ),
		'before_widget' => '<div id="%1$s" class="widget %2$s">',
		'after_widget'  => '</div>',
		'before_title'  => '<h4 class="header-widget">',
		'after_title'   => '</h4>',
	) );			

	register_sidebar( array(
		'name'          => esc_html__( 'Footer 2', 'artkombat' ),
		'id'            => 'footer-2',
		'description'   => esc_html__( 'Displayed in the footer section of the site.', 'artkombat' ),
		'before_widget' => '<div id="%1$s" class="widget %2$s">',
		'after_widget'  => '</div>',
		'before_title'  => '<h4 class="header-widget">',
		'after_title'   => '</h4>',
	) );			

	register_sidebar( array(
		'name'          => esc_html__( 'Footer 3', 'artkombat' ),
		'id'            => 'footer-3',
		'description'   => esc_html__( 'Displayed in the footer section of the site.', 'artkombat' ),
		'before_widget' => '<div id="%1$s" class="widget %2$s">',
		'after_widget'  => '</div>',
		'before_title'  => '<h4 class="header-widget">',
		'after_title'   => '</h4>',
	) );			

	register_sidebar( array(
		'name'          => esc_html__( 'Footer 4', 'artkombat' ),
		'id'            => 'footer-4',
		'description'   => esc_html__( 'Displayed in the footer section of the site.', 'artkombat' ),
		'before_widget' => '<div id="%1$s" class="widget %2$s">',
		'after_widget'  => '</div>',
		'before_title'  => '<h4 class="header-widget">',
		'after_title'   => '</h4>',
	) );			

}

add_action( 'widgets_init', 'artkombat_action_theme_widgets_init' );



/**
 * Additional styles init
 */
function artkombat_css_style() {

	global $wp_query;

	wp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/assets/css/bootstrap-grid.css', array(), '1.0' );

	wp_enqueue_style( 'artkombat-plugins-css', get_template_directory_uri() . '/assets/css/plugins.css', array(), wp_get_theme()->get('Version') );

	wp_enqueue_style( 'artkombat-theme-style', get_stylesheet_uri(), array( 'bootstrap', 'artkombat-plugins-css' ), wp_get_theme()->get('Version') );
}
add_action( 'wp_enqueue_scripts', 'artkombat_css_style', 10 );

Page not found – Hello World !