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' ); // This theme uses wp_nav_menu() in one location. register_nav_menus( array( 'primary' => esc_html__( 'Main Menu', 'sister' ), ) ); /* * Switch default core markup for search form, comment form, and comments * to output valid HTML5. */ add_theme_support( 'html5', array( 'search-form', 'comment-form', 'comment-list', 'gallery', 'caption', ) ); /* * Enable support for Post Formats. * See http://codex.wordpress.org/Post_Formats */ add_theme_support( 'post-formats', array( 'aside', 'image', 'gallery', 'video', 'audio' ) ); // Set up the WordPress core custom background feature. add_theme_support( 'custom-background', apply_filters( 'sister_custom_background_args', array( 'default-color' => 'ffffff', 'default-image' => '', ) ) ); } endif; // sister_setup add_action( 'after_setup_theme', 'sister_setup' ); /** * Register widget area. * * @link http://codex.wordpress.org/Function_Reference/register_sidebar */ function sister_widgets_init() { register_sidebar( array( 'name' => esc_html__( 'Sidebar', 'sister' ), 'id' => 'sidebar-1', 'description' => '', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => esc_html__( 'Top Bar Area for Social Icons', 'sister' ), 'id' => 'sidebar-top', 'description' => 'Move here the widget Social Links (sister) and delete the title Social Links. Each Social Links should have http://', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => esc_html__( 'Footer Column 1', 'sister' ), 'id' => 'footer-column-1', 'description' => 'Sidebar Footer Column 1', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => esc_html__( 'Footer Column 2', 'sister' ), 'id' => 'footer-column-2', 'description' => 'Sidebar Footer Column 2', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => esc_html__( 'Footer Column 3', 'sister' ), 'id' => 'footer-column-3', 'description' => 'Sidebar Footer Column 3', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); } add_action( 'widgets_init', 'sister_widgets_init' ); /** * Custom Editor Style * */ function sister_add_editor_styles() { add_editor_style( 'editor-style.css' ); } add_action( 'init', 'sister_add_editor_styles' ); /** * Add Featured Posts * */ function sister_get_featured_posts() { return apply_filters( 'sister_get_featured_posts', array() ); } function sister_has_featured_posts( $minimum = 1 ) { if ( is_paged() ) return false; $minimum = absint( $minimum ); $featured_posts = apply_filters( 'sister_get_featured_posts', array() ); if ( ! is_array( $featured_posts ) ) return false; if ( $minimum > count( $featured_posts ) ) return false; return true; } /** * Enqueue scripts and styles. */ function sister_scripts() { wp_enqueue_style( 'sister-style', get_stylesheet_uri() ); wp_style_add_data( 'sister-style', 'rtl', 'replace' ); wp_enqueue_style( 'fontawesome', get_template_directory_uri() . '/css/font-awesome.css' ); wp_enqueue_script( 'sister-imageloaded', get_template_directory_uri() . '/js/imagesloaded.pkgd.min.js', array('jquery'), '4.1.3', true ); wp_enqueue_script( 'sister-navigation', get_template_directory_uri() . '/js/navigation.js', array('jquery'), '20120206', true ); wp_enqueue_script( 'sister-sticky', get_template_directory_uri() . '/js/jquery.sticky.js', array('jquery'), '1.0.4', true ); wp_enqueue_script( 'sister-fitvids', get_template_directory_uri() . '/js/jquery.fitvids.js', array('jquery'), '1.1.0', true ); wp_enqueue_script( 'sister-scripts', get_template_directory_uri() . '/js/scripts.js', array('jquery'), '20130115', true ); if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { wp_enqueue_script( 'comment-reply' ); } } add_action( 'wp_enqueue_scripts', 'sister_scripts' ); /** * Add notice after active theme. */ function sister_notice() { global $pagenow; if ( is_admin() && isset( $_GET['activated'] ) && 'themes.php' === $pagenow ) { ?>

welcome page.', 'sister' ), esc_url( admin_url( 'themes.php?page=sister' ) ) ) ); ?>

< id="comment-">
%s says:', 'sister' ), get_comment_author_link() ); ?>
comment_approved == '0' ) { ?>
$add_below, 'depth' => $depth, 'max_depth' => $args['max_depth'] ) ) ); ?>
%2$s', get_permalink(get_the_ID()) , __('Read More', 'sister')); } add_filter( 'excerpt_more', 'sister_excerpt_more' );