__( 'Primary Menu', 'bricks' ), ) ); // Enable support for Post Formats. add_theme_support( 'post-formats', array( 'aside', 'image', 'video', 'quote', 'link' ) ); // Setup the WordPress core custom background feature. add_theme_support( 'custom-background', apply_filters( 'bricks_custom_background_args', array( 'default-color' => 'ffffff', 'default-image' => '', ) ) ); // Enable support for HTML5 markup. add_theme_support( 'html5', array( 'comment-list', 'search-form', 'comment-form', ) ); } endif; // bricks_setup add_action( 'after_setup_theme', 'bricks_setup' ); /** * Register widgetized area and update sidebar with default widgets. */ function bricks_widgets_init() { register_sidebar( array( 'name' => __( 'Sidebar', 'bricks' ), 'id' => 'sidebar-1', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); } add_action( 'widgets_init', 'bricks_widgets_init' ); /** * Enqueue scripts and styles. */ function bricks_scripts() { wp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/css/bootstrap.css' ); wp_enqueue_style( 'bootstrap-theme', get_template_directory_uri() . '/css/bootstrap-theme.min.css' ); wp_enqueue_style( 'bricks-style', get_stylesheet_uri() ); wp_enqueue_script( 'custom', get_template_directory_uri() . '/js/main.js', array('jquery'),'', true ); wp_enqueue_script( 'imageload', get_template_directory_uri() . '/js/imageLoaded.js', array('jquery','custom'),'', true ); wp_enqueue_script( 'jquery-masonry', array('jquery'),'', false ); wp_enqueue_script( 'modernizr' ,get_template_directory_uri() . '/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js', array('jquery'),'', true ); wp_enqueue_script( 'bootstrap-js', get_template_directory_uri() . '/js/vendor/bootstrap.min.js', array('jquery'),'', true ); wp_enqueue_script( 'bricks-skip-link-focus-fix', get_template_directory_uri() . '/js/skip-link-focus-fix.js', array(), '20130115', true ); wp_enqueue_style('googlefont-first', '//fonts.googleapis.com/css?family=Josefin+Sans:400,700'); wp_enqueue_style('googlefont-second', '//fonts.googleapis.com/css?family=Montserrat' ); if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { wp_enqueue_script( 'comment-reply' ); } } add_action( 'wp_enqueue_scripts', 'bricks_scripts' ); /*function custom_theme_js(){ wp_register_script( 'infinite_scroll', get_template_directory_uri() . '/js/jquery.infinitescroll.min.js', array('jquery'),null,true ); if( ! is_singular() ) { wp_enqueue_script('infinite_scroll'); } }*/ /*if ( ! function_exists( 'bricks_content_nav' ) ) : function bricks_content_nav( $html_id ) { global $wp_query; $html_id = esc_attr( $html_id ); if ( $wp_query->max_num_pages > 1 ) : ?> max_num_pages <= 1 ) return; $paged = get_query_var( 'paged' ) ? absint( get_query_var( 'paged' ) ) : 1; $max = intval( $wp_query->max_num_pages ); /** Add current page to the array */ if ( $paged >= 1 ) $links[] = $paged; /** Add the pages around the current page to the array */ if ( $paged >= 3 ) { $links[] = $paged - 1; $links[] = $paged - 2; } if ( ( $paged + 2 ) <= $max ) { $links[] = $paged + 2; $links[] = $paged + 1; } echo '' . "\n"; } function bricks_customize_register_option($wp_customize){ /***For Container Color**/ $wp_customize->add_section('bricks_color_scheme', array( 'title' => __('Color Scheme', 'bricks'), 'priority' => 120, )); $wp_customize->add_setting('bricks_theme_options', array( 'default' => '#FFFFFF', 'sanitize_callback' => 'sanitize_hex_color', 'capability' => 'edit_theme_options', 'type' => 'option', )); $wp_customize->add_control( new WP_Customize_Color_Control($wp_customize, 'link_color', array( 'label' => __('Box Color ', 'bricks'), 'section' => 'bricks_color_scheme', 'settings' => 'bricks_theme_options', ))); $wp_customize->add_section( 'bricks_logo_section' , array( 'title' => __( 'Logo', 'bricks' ), 'priority' => 30, 'description' => 'Upload a logo to replace the default site name and description in the header', )); $wp_customize->add_setting( 'bricks_logo' ); $wp_customize->add_control( new WP_Customize_Image_Control( $wp_customize, 'bricks_logo', array( 'label' => __( 'Logo', 'bricks' ), 'section' => 'bricks_logo_section', 'settings' => 'bricks_logo', ))); /************End**************/ } add_action('customize_register', 'bricks_customize_register_option'); function bricks_custom_style(){ echo ''; } add_action( 'wp_head','bricks_custom_style'); /** * Implement the Custom Header feature. */ require get_template_directory() . '/inc/custom-header.php'; /** * Custom template tags for this theme. */ require get_template_directory() . '/inc/template-tags.php'; /** * Custom functions that act independently of the theme templates. */ require get_template_directory() . '/inc/extras.php'; /** * Customizer additions. */ require get_template_directory() . '/inc/customizer.php'; /** * Load Jetpack compatibility file. */ require get_template_directory() . '/inc/jetpack.php'; /*if(is_admin()) { add_action('wp_head', 'show_template'); function show_template() { global $template; echo basename($template); } }*/ require_once('briks_navwalker.php');