'left_sidebar', 'name'=>__( 'Left Sidebar', 'blacklens' ), 'before_widget' => '', 'after_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); register_nav_menus( array( 'top_nav' => __( 'Top Navigation menu', 'blacklens' ) , ) ); add_theme_support('automatic-feed-links'); if ( ! isset( $content_width ) ) $content_width = 640; add_action( 'wp_enqueue_scripts', 'blacklens_enqueue_css' ); add_action( 'customize_register' , 'blacklens_theme_customizer' ); add_filter( 'wp_title', 'blacklens_filter_wp_title', 10, 3 ); add_action( 'comment_form_before', 'blacklens_enqueue_comment_reply_script' ); } function blacklens_enqueue_css() { wp_enqueue_style( 'blacklens', get_stylesheet_uri() ); } function blacklens_enqueue_comment_reply_script() { if ( comments_open() && get_option( 'thread_comments' ) ) { wp_enqueue_script( 'comment-reply' ); } } function blacklens_theme_customizer ( $wp_customizer ) { $wp_customizer->add_section( 'blacklens_date_and_author_section', array( 'title' => __( 'Date & Author name', 'blacklens' ), 'priority' => 34 ) ); $wp_customizer->add_setting( 'blacklens_rad_show_date', array( 'default' => 'y', 'type' => 'option', 'capability' => 'edit_theme_options', ) ); $wp_customizer->add_control( 'blacklens_rad_show_date', array( 'label' => __( 'Show date in posts?', 'blacklens' ), 'section' => 'blacklens_date_and_author_section', 'settings' => 'blacklens_rad_show_date', 'type' => 'radio', 'choices' => array( 'y' => __( 'Yes', 'blacklens' ), 'n' => __( 'No', 'blacklens' ) ) ) ); $wp_customizer->add_setting( 'blacklens_rad_show_author', array( 'default' => 'y', 'type' => 'option', 'capability' => 'edit_theme_options', ) ); $wp_customizer->add_control( 'blacklens_rad_show_author', array( 'label' => __( "Show author's name in posts?", 'blacklens' ), 'section' => 'blacklens_date_and_author_section', 'settings' => 'blacklens_rad_show_author', 'type' => 'radio', 'choices' => array( 'y' => __( 'Yes', 'blacklens' ), 'n' => __( 'No', 'blacklens' ) ) ) ); $wp_customizer->add_section( 'blacklens_color_section', array( 'title' => __( 'Colors', 'blacklens' ), 'priority' => 35 ) ); $wp_customizer->add_setting( 'blacklens_color_post_title', array( 'default' => '#ec008c', 'type' => 'option', 'capability' => 'edit_theme_options', ) ); $wp_customizer->add_control( new WP_Customize_Color_Control( $wp_customizer, 'post_title_color', array( 'label' => __( 'Post Title Color', 'blacklens' ), 'section' => 'blacklens_color_section', 'settings' => 'blacklens_color_post_title', ) ) ); } function blacklens_nav_fallback() { $pages = get_pages( array( 'number' => 6, 'hierarchical' => 0, ) ); if( $pages ) { ?>