', esc_url( get_bloginfo( 'pingback_url' ) ) ); } } add_action( 'wp_head', 'blog_bogo_pingback_header' ); if (!function_exists('blog_bogo_get_terms')): function blog_bogo_get_terms($taxonomy = 'category', $category_id = 0, $default = '') { $taxonomy = !empty($taxonomy) ? $taxonomy : 'category'; if ($category_id > 0) { $term = get_term_by('id', absint($category_id), $taxonomy); if ($term) return esc_html($term->name); } else { $terms = get_terms(array( 'taxonomy' => $taxonomy, 'orderby' => 'name', 'order' => 'ASC', 'hide_empty' => true, )); if (isset($terms) && !empty($terms)) { foreach ($terms as $term) { if ($default != 'first') { $array['0'] = __('Select Category', 'blog-bogo'); } $array[$term->term_id] = esc_html($term->name); } return $array; } } } endif; if ( ! function_exists( 'blog_bogo_widgets' ) ) : /** * Load widgets. * * @since 1.0.0 */ function blog_bogo_widgets() { register_widget( 'Blog_Bogo_Posts_Latest' ); register_widget( 'Blog_Bogo_Author_Profile' ); } endif; add_action( 'widgets_init', 'blog_bogo_widgets' ); if( ! function_exists( 'blog_bogo_primary_navigation_fallback' ) ) : /** * Fallback for primary navigation. * * @since 1.0.0 */ function blog_bogo_primary_navigation_fallback() { echo ''; } endif;