'; // tag before the current crumb $after = ''; // tag after the current crumb if ( !is_home() && !is_front_page() || is_paged() ) { echo '
'; global $post; $homeLink = home_url(); echo '' . $home . ' ' . $delimiter . ' '; if ( is_category() ) { global $wp_query; $cat_obj = $wp_query->get_queried_object(); $thisCat = $cat_obj->term_id; $thisCat = get_category($thisCat); $parentCat = get_category($thisCat->parent); if ($thisCat->parent != 0) echo(get_category_parents($parentCat, TRUE, ' ' . $delimiter . ' ')); echo $before . 'Archive for category "' . single_cat_title('', false) . '"' . $after; } elseif ( is_day() ) { echo '' . get_the_time('Y') . ' ' . $delimiter . ' '; echo '' . get_the_time('F') . ' ' . $delimiter . ' '; echo $before . get_the_time('d') . $after; } elseif ( is_month() ) { echo '' . get_the_time('Y') . ' ' . $delimiter . ' '; echo $before . get_the_time('F') . $after; } elseif ( is_year() ) { echo $before . get_the_time('Y') . $after; } elseif ( is_single() && !is_attachment() ) { if ( get_post_type() != 'post' ) { $post_type = get_post_type_object(get_post_type()); $slug = $post_type->rewrite; echo '' . $post_type->labels->singular_name . ' ' . $delimiter . ' '; echo $before . get_the_title() . $after; } else { $cat = get_the_category(); $cat = $cat[0]; echo get_category_parents($cat, TRUE, ' ' . $delimiter . ' '); echo $before . get_the_title() . $after; } } elseif ( !is_single() && !is_page() && get_post_type() != 'post' && !is_404() ) { $post_type = get_post_type_object(get_post_type()); echo $before . $post_type->labels->singular_name . $after; } elseif ( is_attachment() ) { $parent = get_post($post->post_parent); $cat = get_the_category($parent->ID); $cat = $cat[0]; echo get_category_parents($cat, TRUE, ' ' . $delimiter . ' '); echo '' . $parent->post_title . ' ' . $delimiter . ' '; echo $before . get_the_title() . $after; } elseif ( is_page() && !$post->post_parent ) { echo $before . get_the_title() . $after; } elseif ( is_page() && $post->post_parent ) { $parent_id = $post->post_parent; $breadcrumbs = array(); while ($parent_id) { $page = get_page($parent_id); $breadcrumbs[] = '' . get_the_title($page->ID) . ''; $parent_id = $page->post_parent; } $breadcrumbs = array_reverse($breadcrumbs); foreach ($breadcrumbs as $crumb) echo $crumb . ' ' . $delimiter . ' '; echo $before . get_the_title() . $after; } elseif ( is_search() ) { echo $before . 'Search results for "' . get_search_query() . '"' . $after; } elseif ( is_tag() ) { echo $before . 'Posts tagged "' . single_tag_title('', false) . '"' . $after; } elseif ( is_author() ) { global $author; $userdata = get_userdata($author); echo $before . 'Articles posted by ' . $userdata->display_name . $after; } elseif ( is_404() ) { echo $before . 'Error 404' . $after; } if ( get_query_var('paged') ) { if ( is_category() || is_day() || is_month() || is_year() || is_search() || is_tag() || is_author() ) echo ' ('; echo __( 'Page', 'ifeature') . ' ' . get_query_var('paged'); if ( is_category() || is_day() || is_month() || is_year() || is_search() || is_tag() || is_author() ) echo ')'; } echo '
'; } } // end ifeature_breadcrumbs() if ( ! isset( $content_width ) ) $content_width = 900; /* Begin custom excerpt functions. */ function business_new_excerpt_more($more) { global $options; if ($options['bu_excerpt_link_text'] == '') { $linktext = '(Read More...)'; } else { $linktext = $options['bu_excerpt_link_text']; } global $post; return '

'.$linktext.'
'; } add_filter('excerpt_more', 'business_new_excerpt_more'); function business_new_excerpt_length($length) { global $options; if ($options['bu_excerpt_length'] == '') { $length = '55'; } else { $length = $options['bu_excerpt_length']; } return $length; } add_filter('excerpt_length', 'business_new_excerpt_length'); /* End excerpt functions. */ /* Add auto-feed links support. */ add_theme_support('automatic-feed-links'); /* Add post-thumb support. */ if ( function_exists( 'add_theme_support' ) ) { global $options; if($options['bu_featured_image_height'] == "") { $featureheight = '100'; } else { $featureheight = $options['bu_featured_image_height']; } if ($options['bu_featured_image_width'] == "") { $featurewidth = '100'; } else { $featurewidth = $options['bu_featured_image_width']; } add_theme_support( 'post-thumbnails' ); set_post_thumbnail_size( $featureheight, $featurewidth, true ); } // This theme allows users to set a custom background add_custom_background(); // This theme styles the visual editor with editor-style.css to match the theme style. add_editor_style(); /** * Attach CSS3PIE behavior to elements * Add elements here that need PIE applied */ function business_render_ie_pie() { ?> "; echo $script; } add_action('wp_head', 'business_plusone'); // Load jQuery function bu_jquery() { if ( !is_admin() ) { wp_enqueue_script('jquery'); } } add_action('wp_enqueue_scripts', 'bu_jquery'); // Nivo Slider function business_add_nivoslider(){ $path = get_template_directory_uri() ."/library/ns/"; $script = " "; echo $script; } add_action('wp_head', 'business_add_nivoslider'); // Register superfish scripts function business_add_scripts() { if (!is_admin()) { // Add the scripts, but not to the wp-admin section. // Adjust the below path to where scripts dir is, if you must. $scriptdir = get_template_directory_uri() ."/library/sf/"; // Register the Superfish javascript file wp_register_script( 'superfish', $scriptdir.'sf.js', false, '1.4.8'); wp_register_script( 'sf-menu', $scriptdir.'sf-menu.js'); // Now the superfish CSS //load the scripts and style. wp_enqueue_style('superfish-css'); wp_enqueue_script('superfish'); wp_enqueue_script('sf-menu'); } // end the !is_admin function } //end add_our_scripts function //Add our function to the wp_head. You can also use wp_print_scripts. add_action( 'wp_head', 'business_add_scripts',0); // Register menu names function register_business_menus() { register_nav_menus( array( 'header-menu' => 'Header Menu' ) ); } add_action( 'init', 'register_business_menus' ); // Menu fallback function business_menu_fallback() { global $post; ?> 'Sidebar Widgets', 'id' => 'sidebar-widgets', 'description' => 'These are widgets for the sidebar.', 'before_widget' => '', 'before_title' => '' )); register_sidebar(array( 'name' => 'Footer', 'before_widget' => '', 'before_title' => '', )); } add_action( 'widgets_init', 'business_sidebars' ); function business_admin_link() { global $wp_admin_bar; $wp_admin_bar->add_menu( array( 'id' => 'Business lite', 'title' => 'Business lite Settings', 'href' => admin_url('themes.php?page=theme_options') ) ); } add_action( 'admin_bar_menu', 'business_admin_link', 113 ); //Business Pro options file require_once ( get_template_directory() . '/library/options/options.php' ); require_once ( get_template_directory() . '/library/options/options-themes.php' ); require_once ( get_template_directory() . '/library/options/meta-box.php' ); ?>