tag in the document head, and expect WordPress to * provide it for us. */ add_theme_support( 'title-tag' ); /* * Enable support for Post Thumbnails on posts and pages. * * @link http://codex.wordpress.org/Function_Reference/add_theme_support#Post_Thumbnails */ add_theme_support( 'post-thumbnails' ); add_image_size( 'post-thumb', 800, 600, true ); // This theme uses wp_nav_menu() in one location. register_nav_menus( array( 'primary' => esc_html__( 'Header Menu', 'beagency' ), 'secondary' => esc_html__( 'Footer Menu', 'beagency' ) ) ); /* * Switch default core markup for search form, comment form, and comments * to output valid HTML5. */ add_theme_support( 'html5', array( 'gallery', 'caption', ) ); /* * Enable support for Post Formats. * See http://codex.wordpress.org/Post_Formats */ add_theme_support( 'post-formats', array( 'image' ) ); } endif; // beagency_setup add_action( 'after_setup_theme', 'beagency_setup' ); /** * Set the content width in pixels, based on the theme's design and stylesheet. * * Priority 0 to make it available to lower priority callbacks. * * @global int $content_width */ function beagency_content_width() { $GLOBALS['content_width'] = apply_filters( 'beagency_content_width', 1140 ); } add_action( 'after_setup_theme', 'beagency_content_width', 0 ); /** * Register widget area. * * @link http://codex.wordpress.org/Function_Reference/register_sidebar */ function beagency_widgets_init() { register_sidebar( array( 'name' => esc_html__( 'Sidebar', 'beagency' ), 'id' => 'sidebar-right', 'description' => 'It will show in blog single page and search page.', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); } add_action( 'widgets_init', 'beagency_widgets_init' ); /** * Enqueue scripts and styles. */ function beagency_scripts() { wp_enqueue_style( 'bootstrap-style', get_template_directory_uri() . '/layouts/bootstrap.min.css', array(), '3.3.6' ); wp_enqueue_style( 'font-awesome-style', get_template_directory_uri() . '/layouts/font.awesome.min.css', array(), '4.5.0' ); wp_enqueue_style( 'magnific-popup-style', get_template_directory_uri() . '/layouts/magnific.popup.css', array(), '1.0.1' ); wp_enqueue_style( 'owl-carousel-style', get_template_directory_uri() . '/layouts/owl.carousel.min.css', array(), '2.0.0-beta.2.4' ); wp_enqueue_style( 'owl-carousel-theme-style', get_template_directory_uri() . '/layouts/owl.theme.default.min.css', array(), '2.0.0-beta.2.4' ); wp_enqueue_style( 'beagency-style', get_stylesheet_uri() ); wp_enqueue_style( 'beagency-responsive-style', get_template_directory_uri() . '/layouts/responsive.css', array(), beagency_get_version() ); wp_enqueue_script('jquery'); wp_enqueue_script( 'jRespond-script', get_template_directory_uri() . '/js/jrespond.min.js', array(), '0.10', true ); wp_enqueue_script( 'superfish-script', get_template_directory_uri() . '/js/superfish.min.js', array(), '1.7.7', true ); wp_enqueue_script( 'portfolioimg-script', get_template_directory_uri() . '/js/portfolio-images.pkgd.min.js', array(), '4.0.0', true ); wp_enqueue_script( 'isotope-script', get_template_directory_uri() . '/js/isotope.pkgd.min.js', array(), '2.2.2', true ); wp_enqueue_script( 'easing-script', get_template_directory_uri() . '/js/jquery.easing.min.js', array(), '1.3.2', true ); wp_enqueue_script( 'magnific-popup-script', get_template_directory_uri() . '/js/jquery.magnific.popup.min.js', array(), '1.0.1', true ); wp_enqueue_script( 'owl-carousel-script', get_template_directory_uri() . '/js/owl.carousel.min.js', array(), '2.0.0-beta.2.4', true ); wp_enqueue_script( 'smoothscroll-script', get_template_directory_uri() . '/js/smoothscroll.min.js', array(), '1.4.1', true ); wp_enqueue_script( 'infinitescroll-script', get_template_directory_uri() . '/js/jquery.infinitescroll.min.js', array(), '2.1.0', true ); wp_enqueue_script( 'beagency-custom-script', get_template_directory_uri() . '/js/custom.js', array('jquery'),null, true ); wp_enqueue_script( 'beagency-app-script', get_template_directory_uri() . '/js/jquery.app.js', array( 'jquery' ), beagency_get_version(), true ); // Localize the script with new data. wp_localize_script( 'beagency-app-script', 'beagency_app_vars', array( 'ajax_url' => esc_url(admin_url( 'admin-ajax.php' )) ) ); if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { wp_enqueue_script( 'comment-reply' ); } } add_action( 'wp_enqueue_scripts', 'beagency_scripts' ); /** * Include the TGM_Plugin_Activation class. */ require_once get_template_directory() . '/inc/tgmpa/tgm-plugin-activation.php'; /** * Load Kirki Customizer Toolkit. */ require_once get_template_directory() . '/inc/kirki/kirki.php'; /** * Load Customizer configuration. */ require_once get_template_directory() . '/inc/kirki/config.php'; /** * Custom template tags for this theme. */ require_once get_template_directory() . '/inc/template-tags.php'; /** * Comments Callback. */ require_once get_template_directory() . '/inc/comments-callback.php'; /** * Custom functions that act independently of the theme templates. */ require_once get_template_directory() . '/inc/extras.php';