__( 'Primary Menu', 'pluto' ), 'footer' => __('Footer Menu', 'pluto' ) ) ); /** * 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( 'pluto_custom_background_args', array( 'default-color' => 'f7f7f7', 'default-image' => '', ) ) ); add_editor_style( 'custom-editor-style.css' ); } endif; // pluto_setup add_action( 'after_setup_theme', 'pluto_setup' ); /** * Register widgetized area and update sidebar with default widgets */ function pluto_widgets_init() { register_sidebar( array( 'name' => __( 'Sidebar', 'pluto' ), 'id' => 'sidebar-1', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); } add_action( 'widgets_init', 'pluto_widgets_init' ); /** * Enqueue scripts and styles */ function pluto_scripts() { wp_enqueue_style( 'pluto-style', get_stylesheet_uri(), array('pluto-slider-style', 'pluto-fonts') ); wp_enqueue_style( 'pluto-fonts', '//fonts.googleapis.com/css?family=Lato:300,400,700' ); wp_enqueue_style( 'pluto-slider-style', get_template_directory_uri()."/css/jquery.bxslider.css" ); wp_enqueue_script( 'pluto-navigation', get_template_directory_uri() . '/js/navigation.js', array(), '20120206', true ); wp_enqueue_script( 'pluto-slider', get_template_directory_uri() . '/js/jquery.bxslider.min.js', array('jquery') ); wp_enqueue_script( 'pluto-skip-link-focus-fix', get_template_directory_uri() . '/js/skip-link-focus-fix.js', array(), '20130115', true ); if ( ( of_get_option('slider_enabled') != 0 ) && ( (is_home() == true) || (is_front_page() == true) ) ) { wp_enqueue_script( 'pluto-custom-js', get_template_directory_uri() . '/js/custom.js', array('jquery','pluto-slider') ); } if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { wp_enqueue_script( 'comment-reply' ); } if ( is_singular() && wp_attachment_is_image() ) { wp_enqueue_script( 'pluto-keyboard-image-navigation', get_template_directory_uri() . '/js/keyboard-image-navigation.js', array( 'jquery' ), '20120202' ); } } add_action( 'wp_enqueue_scripts', 'pluto_scripts' ); function pluto_custom_head_codes() { if ( (function_exists( 'of_get_option' )) && (of_get_option('customcss1', true) != 1) ) { echo ""; } } add_action('wp_head', 'pluto_custom_head_codes'); /** * Custom template tags for this theme. */ require get_template_directory() . '/inc/template-tags.php'; class Pluto_Recent_Posts extends WP_Widget { public function __construct() { parent::__construct( 'pluto_rp', // Base ID __('Pluto Recent Posts', 'pluto'), // Name array( 'description' => __( 'Display your recent posts, with a Thumbnail.', 'pluto' ), ) // Args ); } public function widget( $args, $instance ) { $title = apply_filters( 'widget_title', $instance['title'] ); $no_of_posts = apply_filters( 'no_of_posts', $instance['no_of_posts'] ); echo $args['before_widget']; if ( ! empty( $title ) ) echo $args['before_title'] . $title . $args['after_title']; // WP_Query arguments $qa = array ( 'post_type' => 'post', 'posts_per_page' => $no_of_posts, 'offset' => 0, 'ignore_sticky_posts' => 1 ); // The Query $recent_articles = new WP_Query( $qa ); if($recent_articles->have_posts()) : ?>

str_replace( $big, '%#%', esc_url( get_pagenum_link( $big ) ) ), 'format' => '?paged=%#%', 'current' => max( 1, get_query_var('paged') ), 'total' => $wp_query->max_num_pages, 'type' => 'array' ) ); if( is_array($page_format) ) { $paged = ( get_query_var('paged') == 0 ) ? 1 : get_query_var('paged'); echo ''; } } add_action('pluto-content-below', 'pluto_pagination' ); /** * 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';