%3$s', get_permalink(), esc_attr(get_the_time()), get_the_date('F d, Y')), sprintf('%3$s', get_author_posts_url(get_the_author_meta('ID')), esc_attr(sprintf(__('View all posts by $s', 'beyond-expectations'), get_the_author())), get_the_author() )); } } /* ================================================================================================ 2.0 - Comments ================================================================================================ */ if (!function_exists('beyond_expectations_add_comments_setup')) { function beyond_expectations_add_comments_setup() { if (comments_open()) { comments_popup_link('Add Comment','1 Comment','% Comments'); } else { _e('Comments are Closed', 'beyond-expectations'); } } } /* ================================================================================================ 2.0 - Metadata Posted In ================================================================================================ if (!function_exists('beyond_expectations_cat_tag_setup')) { function beyond_expectations_cat_tag_setup() { ?> __( 'Primary Sidebar', 'beyond-expectations' ), 'id' => 'primary-sidebar', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); register_sidebar(array( 'name' => __( 'Secondary Sidebar', 'beyond-expectations' ), 'id' => 'secondary-sidebar', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); register_sidebar(array( 'name' => __( 'Custom Sidebar', 'beyond-expectations' ), 'id' => 'custom-sidebar', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); } add_action('widgets_init', 'beyond_expectations_custom_widgets_init_setup'); } /* ================================================================================================ 4.0 - Pagination Navigation ================================================================================================ */ if (!function_exists('beyond_expectations_paging_navigation_setup')) { function beyond_expectations_paging_navigation_setup() { // Don't print empty markup if there's only one page. if ( $GLOBALS['wp_query']->max_num_pages < 2 ) { return; } $paged = get_query_var( 'paged' ) ? intval( get_query_var( 'paged' ) ) : 1; $pagenum_link = html_entity_decode( get_pagenum_link() ); $query_args = array(); $url_parts = explode( '?', $pagenum_link ); if ( isset( $url_parts[1] ) ) { wp_parse_str( $url_parts[1], $query_args ); } $pagenum_link = remove_query_arg( array_keys( $query_args ), $pagenum_link ); $pagenum_link = trailingslashit( $pagenum_link ) . '%_%'; $format = $GLOBALS['wp_rewrite']->using_index_permalinks() && ! strpos( $pagenum_link, 'index.php' ) ? 'index.php/' : ''; $format .= $GLOBALS['wp_rewrite']->using_permalinks() ? user_trailingslashit( 'page/%#%', 'paged' ) : '?paged=%#%'; // Set up paginated links. $links = paginate_links( array( 'base' => $pagenum_link, 'format' => $format, 'total' => $GLOBALS['wp_query']->max_num_pages, 'current' => $paged, 'mid_size' => 2, 'add_args' => array_map( 'urlencode', $query_args ), 'prev_text' => __( 'Previous', 'beyond-expectations' ), 'next_text' => __( 'Next', 'beyond-expectations' ), 'type' => 'list', ) ); if ( $links ) : ?> 'social-navigation', 'container' => 'div', 'container_id' => 'menu-social', 'container_class' => 'menu-social', 'menu_id' => 'menu-social-items', 'menu_class' => 'menu-items', 'depth' => 1, 'link_before' => '', 'link_after' => '', 'fallback_cb' => '', )); }; } }