'ffffff' ); add_theme_support( 'custom-background', $nimbus_custom_background_defaults ); // Register Menus if (function_exists('register_nav_menu')) { register_nav_menu('mobile', __('Mobile Menu', 'nimbus')); register_nav_menu('top-bar', __('Primary Menu', 'nimbus')); } } endif; /* * *************************************************************************************************** */ // Override gallery style /* * *************************************************************************************************** */ add_filter( 'use_default_gallery_style', '__return_false' ); /* * *************************************************************************************************** */ // Set Content Width /* * *************************************************************************************************** */ if (!isset($content_width)) $content_width = 770; /* * *************************************************************************************************** */ // Register Sidebars /* * *************************************************************************************************** */ add_action('widgets_init', 'nimbus_register_sidebars'); function nimbus_register_sidebars() { register_sidebar(array( 'name' => __('Frontpage Sidebar', 'nimbus'), 'id' => 'sidebar_frontpage', 'description' => __('Widgets in this area will be displayed in the sidebar on the frontpage.', 'nimbus'), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

' )); register_sidebar(array( 'name' => __('Default Page Sidebar', 'nimbus'), 'id' => 'sidebar_pages', 'description' => __('Widgets in this area will be displayed in the sidebar on the pages.', 'nimbus'), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

' )); register_sidebar(array( 'name' => __('Blog Sidebar', 'nimbus'), 'id' => 'sidebar_blog', 'description' => __('Widgets in this area will be displayed in the sidebar on all blog related post and archives.', 'nimbus'), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

' )); register_sidebar(array( 'name' => __('Footer Left', 'nimbus'), 'id' => 'footer-left', 'description' => __('Widgets in this area will be shown in the left footer column.', 'nimbus'), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

' )); register_sidebar(array( 'name' => __('Footer Center', 'nimbus'), 'id' => 'footer-center', 'description' => __('Widgets in this area will be shown in the center footer column.', 'nimbus'), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

' )); register_sidebar(array( 'name' => __('Footer Right', 'nimbus'), 'id' => 'footer-right', 'description' => __('Widgets in this area will be shown in the right footer column.', 'nimbus'), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

' )); $i = 1; while ($i <= 20) { register_sidebar(array( 'name' => __('Alternative Sidebar', 'nimbus') . $i, 'id' => 'sidebar_' . $i, 'description' => __('Widgets in this area will be displayed in the sidebar for any posts, or pages items that are taged with sidebar', 'nimbus') . $i . '.', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

' )); $i++; } } /* * *************************************************************************************************** */ // Modify Search Form /* * *************************************************************************************************** */ function nimbus_modify_search_form($form) { $form = '
'; if (is_search()) { $form .=''; } else { $form .=''; } $form .= '
'; return $form; } add_filter('get_search_form', 'nimbus_modify_search_form'); /* * *************************************************************************************************** */ // Excerpt Modifications /* * *************************************************************************************************** */ // Excerpt Length add_filter('excerpt_length', 'nimbus_excerpt_length'); function nimbus_excerpt_length($length) { return 80; } // Excerpt More add_filter('excerpt_more', 'nimbus_excerpt_more'); function nimbus_excerpt_more($more) { return '...'; } // Add to pages add_action('init', 'nimbus_add_excerpts_to_pages'); function nimbus_add_excerpts_to_pages() { add_post_type_support('page', 'excerpt'); } /* * *************************************************************************************************** */ // Enable Threaded Comments /* * *************************************************************************************************** */ add_action('wp_enqueue_scripts', 'nimbus_threaded_comments'); function nimbus_threaded_comments() { if (is_singular() && comments_open() && (get_option('thread_comments') == 1)) { wp_enqueue_script('comment-reply'); } } /* * *************************************************************************************************** */ // Modify Comments Output /* * *************************************************************************************************** */ function nimbus_comment($comment, $args, $depth) { $GLOBALS['comment'] = $comment; ?>
  • id="li_comment_">


    __('Leave a Reply', 'nimbus'), 'depth' => $depth, 'max_depth' => $args['max_depth']))) ?>

    comment_approved == '0') : ?>
  • -

    ' . ' ' . ( $req ? '*
    ' : '' ) . '

    '; $fields['email'] = ''; $fields['url'] = '


    ' . '

    '; return $fields; } /* * *************************************************************************************************** */ // Register Featured Image Options Box /* * *************************************************************************************************** */ add_action("admin_init", "nimbus_featured_image_options_meta_box"); function nimbus_featured_image_options_meta_box() { add_meta_box("featured_image_options_meta_box", THEME_NAME . __(' Featured Image Options', 'nimbus'), "nimbus_call_featured_image_options_meta_box", "page", "side", "high"); add_meta_box("featured_image_options_meta_box", THEME_NAME . __(' Featured Image Options', 'nimbus'), "nimbus_call_featured_image_options_meta_box", "post", "side", "high"); } function nimbus_call_featured_image_options_meta_box() { global $post, $wp_query; $custom = get_post_custom($post->ID); if (isset($custom["on_page_checked"])) { $on_page_checked = $custom["on_page_checked"][0]; } echo ''; if (( get_option('page_on_front') == $post->ID )) { ?>

    Include Image at the Top of the Page
    ID); if (isset($custom["alt_sidebar_select"])) { $alt_sidebar_select = $custom["alt_sidebar_select"][0]; } else { $alt_sidebar_select = ""; } echo ''; ?>

    0) ? ' sub-menu' : ''; $output .= "\n$indent