'eeeeee')); // Add Custom Header add_theme_support('custom-header', array( 'header-text' => false, 'width' => 1260, 'height' => 250, 'flex-height' => true)); // Register Navigation Menus register_nav_menu( 'primary', __('Main Navigation', 'airballoon-lite') ); register_nav_menu( 'footer', __('Footer Navigation', 'airballoon-lite') ); // Register Social Icons Menu register_nav_menu( 'social', __('Social Icons', 'airballoon-lite') ); // Add Support for Excerpts on static pages add_post_type_support( 'page', 'excerpt' ); } endif; // Add custom Image Sizes add_action( 'after_setup_theme', 'airballoon_add_image_sizes' ); if ( ! function_exists( 'airballoon_add_image_sizes' ) ): function airballoon_add_image_sizes() { // Add Custom Header Image Size add_image_size( 'custom_header_image', 1260, 250, true); // Add Featured Image Size add_image_size( 'featured_image', 300, 200, true); // Add Slider Image Size add_image_size( 'frontpage_slider_image', 1260, 380, true); // Add Slider Image Size add_image_size( 'frontpage_posts_image', 425, 240, true); // Add Widget Post Thumbnail Size add_image_size( 'widget_post_thumb', 75, 75, true); } endif; // Register Sidebars add_action( 'widgets_init', 'airballoon_register_sidebars' ); if ( ! function_exists( 'airballoon_register_sidebars' ) ): function airballoon_register_sidebars() { // Register Sidebars register_sidebar( array( 'name' => __( 'Sidebar', 'airballoon-lite' ), 'id' => 'sidebar', 'description' => __( 'Appears on posts and pages except front page and fullwidth template.', 'airballoon-lite' ), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); // Register Frontpage Template Widgets register_sidebar( array( 'name' => __( 'Front Page First Row', 'airballoon-lite' ), 'id' => 'frontpage-widgets-first', 'description' => __( 'First three column horizontal widget area on front page template.', 'airballoon-lite' ), 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', )); register_sidebar( array( 'name' => __( 'Front Page Second Row', 'airballoon-lite' ), 'id' => 'frontpage-widgets-second', 'description' => __( 'Second three column horizontal widget area on front page template.', 'airballoon-lite' ), 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', )); } endif; /*==================================== THEME FUNCTIONS ====================================*/ // Creates a better title element text for output in the head section add_filter( 'wp_title', 'airballoon_wp_title', 10, 2 ); function airballoon_wp_title( $title, $sep = '' ) { global $paged, $page; if ( is_feed() ) return $title; // Add the site name. $title .= get_bloginfo( 'name' ); // Add the site description for the home/front page. $site_description = get_bloginfo( 'description', 'display' ); if ( $site_description && ( is_home() || is_front_page() ) ) $title = "$title $sep $site_description"; // Add a page number if necessary. if ( $paged >= 2 || $page >= 2 ) $title = "$title $sep " . sprintf( __( 'Page %s', 'airballoon-lite' ), max( $paged, $page ) ); return $title; } // Add Default Menu Fallback Function function airballoon_default_menu() { echo ''; } // Display Credit Link Function function airballoon_credit_link() { printf(__( 'Powered by %1$s and %2$s.', 'airballoon-lite' ), sprintf( '%s', __( 'WordPress', 'airballoon-lite' ) ), sprintf( '%s', __( 'Air Balloon Theme', 'airballoon-lite' ) ) ); } // Change Excerpt Length add_filter('excerpt_length', 'airballoon_excerpt_length'); function airballoon_excerpt_length($length) { return 58; } // Slideshow Excerpt Length function airballoon_slideshow_excerpt_length($length) { return 8; } // Frontpage Posts Excerpt Length function airballoon_frontpage_posts_excerpt_length($length) { return 20; } // Change Excerpt More add_filter('excerpt_more', 'airballoon_excerpt_more'); function airballoon_excerpt_more($more) { return ''; } // Custom Template for comments and pingbacks. if ( ! function_exists( 'airballoon_list_comments' ) ): function airballoon_list_comments($comment, $args, $depth) { $GLOBALS['comment'] = $comment; if( $comment->comment_type == 'pingback' or $comment->comment_type == 'trackback' ) : ?>
  • id="comment-">

    ', '' ); ?>

  • id="comment-">
    %s', 'airballoon-lite'), get_comment_author_link()) ?>
    comment_approved == '0') : ?>

    $depth, 'max_depth' => $args['max_depth']))) ?>