esc_html__( 'Header - Primary Menu', 'ac-repair' ), 'fixit-footer-menu-first' => esc_html__( 'Footer - Quick Links', 'ac-repair' ), 'fixit-footer-menu-secound' => esc_html__( 'Footer - Locations', 'ac-repair' ), ); if ( !function_exists( 'fixit_function_theme_setup' ) ) { function fixit_function_theme_setup() { /* Load translation domain ---------------------------------------------*/ load_theme_textdomain( 'ac-repair', get_template_directory() . '/language' ); /* Register Menus ------------------------------------------------------*/ foreach( $GLOBALS['fixit_wordpress_menus'] as $key => $value ) register_nav_menus( array( $key => $value )); // Add theme support for Automatic Feed Links add_theme_support( 'automatic-feed-links' ); // Add theme support for document Title tag add_theme_support( 'title-tag' ); // @link http://codex.wordpress.org/Function_Reference/add_theme_support#Post_Thumbnails add_theme_support( 'post-thumbnails' ); // Add theme support for HTML5 Semantic Markup add_theme_support( 'html5', array( 'search-form', 'comment-form', 'comment-list', 'gallery', 'caption' ) ); // Add theme support for Post Formats add_theme_support( 'post-formats', array( 'status', 'quote', 'gallery', 'image', 'video', 'audio', 'link', 'aside', 'chat' ) ); // Add theme support for Custom Background add_theme_support( 'custom-background', array( 'default-color' => 'ffffff', 'default-image' => '', ) ); } add_action( 'after_setup_theme', 'fixit_function_theme_setup' ); } /** * Register widget area. * * @link http://codex.wordpress.org/Function_Reference/register_sidebar */ if( !function_exists('fixit_function_widget_init') ){ function fixit_function_widget_init(){ register_sidebar( array( 'name' => esc_html__( 'Primary Widget Area', 'ac-repair' ), 'id' => 'fixit_widget_id_primary_widget', 'description' => esc_html__( 'Add widgets here to appear in your Sidebar Section Primary Sidebar.', 'ac-repair' ), 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => esc_html__( 'Secondary Widget Area', 'ac-repair' ), 'id' => 'fixit_widget_id_secondary_widget', 'description' => esc_html__( 'Add widgets here to appear in your Sidebar Section Secoudary Sidebar.', 'ac-repair' ), 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => esc_html__( 'Location Widget Area', 'ac-repair' ), 'id' => 'fixit_widget_id_location_widget', 'description' => esc_html__( 'Add widgets here to appear in your Sidebar Section Location Sidebar.', 'ac-repair' ), 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => esc_html__( 'Services Sidebar', 'ac-repair' ), 'id' => 'fixit_widget_id_service_widget', 'description' => esc_html__( 'Add widgets here to appear in your Sidebar Section Services Sidebar.', 'ac-repair' ), 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => esc_html__( 'Footer Section', 'ac-repair' ), 'id' => 'fixit_widget_id_footer_widget', 'description' => esc_html__( 'Add widgets here to appear in your Footer Section.', 'ac-repair' ), 'before_widget' => '', 'before_title' => '', ) ); } add_action( 'widgets_init', 'fixit_function_widget_init' ); } /** * Register Google font in theme. */ if( !function_exists('fixit_function_google_fonts') ){ function fixit_function_google_fonts() { $fixit_google_font_url = ''; $fixit_first_font = _x( 'on', 'Catamaran font: on or off', 'ac-repair' ); if ( 'off' !== $fixit_first_font ) { $fixit_google_font_families = array(); if ( 'off' !== $fixit_first_font ) { $fixit_google_font_families[] = esc_attr('Catamaran:400,700,600,300'); } $query_args = array( 'family' => urlencode( implode( '|', $fixit_google_font_families ) ), 'subset' => urlencode( 'latin,latin-ext' ), ); $fixit_google_font_url = add_query_arg( $query_args, 'https://fonts.googleapis.com/css' ); } return esc_url_raw( $fixit_google_font_url ); } } /** * Enqueue scripts and styles. */ if( !function_exists('fixit_theme_scripts') ){ function fixit_theme_scripts(){ if( !is_admin() ) : // Google Font wp_enqueue_style( 'google-fonts', fixit_function_google_fonts(), array(), null ); // TinyMCE Editor Style wp_enqueue_style( 'fixit-add-editor-style', get_template_directory_uri().'/assets/css/add_editor_style.css'); Fixit_Factory::fixit_enqueue( 'style', 'bootstrap' ); Fixit_Factory::fixit_enqueue( 'style', 'fontawesome' ); Fixit_Factory::fixit_enqueue( 'style', 'fontello' ); Fixit_Factory::fixit_enqueue( 'style', 'magnific-popup' ); /* Page-template Scripts ---------------------------------------------------*/ if( is_page_template('template/front-page.php') || is_home() || is_singular() || is_front_page() || is_search() || is_archive() ){ if( mh_get_option( Fixit_Factory::fixit_prefix() . 'blog_page_layout') === 'masonry-2-column-style' or mh_get_option( Fixit_Factory::fixit_prefix() . 'blog_page_layout') === 'masonry-3-column-style' ){ Fixit_Factory::fixit_enqueue( 'script', 'isotop' ); } Fixit_Factory::fixit_enqueue( 'style', 'slick' ); Fixit_Factory::fixit_enqueue( 'script', 'slick' ); Fixit_Factory::fixit_enqueue( 'script', 'google-map-api' ); wp_enqueue_script('fixit-google-map-script.js', get_template_directory_uri() . '/assets/js/google-map/locations.js', array('fixit-google-map'), null, true ); } if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { // Comment script wp_enqueue_script( 'comment-reply' ); } /** Scripts **/ Fixit_Factory::fixit_enqueue( 'script', 'magnific-popup' ); Fixit_Factory::fixit_enqueue( 'script', 'isotop' ); Fixit_Factory::fixit_enqueue( 'script', 'img-load' ); Fixit_Factory::fixit_enqueue( 'script', 'bootstrap' ); Fixit_Factory::fixit_enqueue( 'script', 'dropdown-menu' ); Fixit_Factory::fixit_enqueue( 'script', 'stick_menu' ); /** required script and style **/ Fixit_Factory::fixit_enqueue( 'style', 'fixit_theme_style' ); Fixit_Factory::fixit_enqueue( 'script', 'fixit_theme_script' ); endif; } add_action( 'wp_enqueue_scripts', 'fixit_theme_scripts', 9999 ); } /** * comment-class-filter */ if( !function_exists('fixit_function_comment_avatar') ){ function fixit_function_comment_avatar($class) { $class = str_replace("class='avatar", "class='img-responsive avatar", $class) ; return $class; } add_filter('get_avatar','fixit_function_comment_avatar'); } /** * Comment Reply link */ if( !function_exists('fixit_function_comment_Reply_Link') ){ function fixit_function_comment_Reply_Link($class){ $class = str_replace("class='comment-reply-link", "class='comment-reply-link btn-link", $class); return $class; } add_filter('comment_reply_link', 'fixit_function_comment_Reply_Link'); } /** * Comment Callback */ if( !function_exists('fixit_function_comment') ){ function fixit_function_comment($comment, $args, $depth) { $GLOBALS['comment'] = $comment; switch ( $comment->comment_type ) : case 'pingback' : case 'trackback' : ?>
  • id="li-comment-">

    comment_approved == '0' ) : ?>
    $depth, 'max_depth' => $args['max_depth'] ) ) ); ?>
    ' . "\n"; print $style; } add_action( 'wp_head', 'fixit_function_favicon_upload'); add_action( 'login_head', 'fixit_function_favicon_upload'); add_action( 'admin_head', 'fixit_function_favicon_upload'); } /** * Add Body Class. */ if( !function_exists( 'fixit_function_body_class' ) ){ function fixit_function_body_class( array $classes ) { $classes[] = sanitize_html_class('fixit_sticky_header'); $classes[] = sanitize_html_class('animsition'); // Removes a class from the body_class array. if (in_array('author-admin', $classes)) { unset( $classes[array_search('author-admin', $classes)] ); } return $classes; } add_filter( 'body_class', 'fixit_function_body_class' ); } /** * Require Plugin Installation. */ Fixit_Factory::fixit_required_plugin_setup(); /** * Fixit Admin Framework */ Fixit_Factory::fixit_framework(); /** * Active Theme Actions */ Fixit_Factory::fixit_theme_active_actions(); ?>