%2$s'; if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) { $time_string = ''; } $time_string = sprintf( $time_string, esc_attr( get_the_date( DATE_W3C ) ), esc_html( get_the_date() ), esc_attr( get_the_modified_date( DATE_W3C ) ), esc_html( get_the_modified_date() ) ); $year = get_the_date('Y'); $month = get_the_date('m'); $day = get_the_date('d'); $link = get_day_link( $year, $month, $day ); $posted_on = sprintf( /* translators: %s: post date. */ esc_html_x( '%s', 'post date', 'blog-prime' ), '' . $time_string . '' ); echo '' . $posted_on . ''; // WPCS: XSS OK. } endif; if ( ! function_exists( 'blog_prime_posted_by' ) ) : /** * Prints HTML with meta information for the current author. */ function blog_prime_posted_by() { $author_img = get_avatar( get_the_author_meta( 'ID' ) , 100, '', '', array( 'class' => 'avatar-img' ) ); echo ' ' .wp_kses_post( $author_img ). ''; $byline = sprintf( /* translators: %s: post author. */ esc_html_x( '%s', 'post author', 'blog-prime' ), '' . esc_html( get_the_author() ) . '' ); echo ' ' . $byline . ''; // WPCS: XSS OK. } endif; if ( ! function_exists( 'blog_prime_comment_count' ) ) : /** * Post Comment Count. */ function blog_prime_comment_count() { echo ''; ?>' . esc_html__( '%1$s', 'blog-prime' ) . '', $categories_list ); // WPCS: XSS OK. } } if( $tags ){ /* translators: used between list items, there is a space after the comma */ $tags_list = get_the_tag_list( '', esc_html_x( ', ', 'list item separator', 'blog-prime' ) ); if ( $tags_list ) { /* translators: 1: list of tags. */ printf( '' . esc_html__( 'Tagged %1$s', 'blog-prime' ) . '', $tags_list ); // WPCS: XSS OK. } } } if( is_single() ){ if ( ! is_single() && ! post_password_required() && ( comments_open() || get_comments_number() ) ) { echo ''; comments_popup_link( sprintf( wp_kses( /* translators: %s: post title */ __( 'Leave a Comment on %s', 'blog-prime' ), array( 'span' => array( 'class' => array(), ), ) ), get_the_title() ) ); echo ''; } } if( $tags && ( is_single() || is_page() ) ){ edit_post_link( sprintf( wp_kses( /* translators: %s: Name of current post. Only visible to screen readers */ __( 'Edit %s', 'blog-prime' ), array( 'span' => array( 'class' => array(), ), ) ), get_the_title() ), '', '' ); } } endif; if ( ! function_exists( 'blog_prime_post_thumbnail' ) ) : /** * Displays an optional post thumbnail. * * Wraps the post thumbnail in an anchor element on index views, or a div * element when on single views. */ function blog_prime_post_thumbnail() { if ( post_password_required() || is_attachment() || ! has_post_thumbnail() ) { return; } $default = blog_prime_get_default_theme_options(); $blog_prime_index_layout = esc_html( get_theme_mod( 'blog_prime_index_layout',$default['blog_prime_index_layout'] ) ); $home_sidebar_layout = esc_html( get_theme_mod( 'home_sidebar_layout',$default['home_sidebar_layout'] ) ); $global_sidebar_layout = esc_html( get_theme_mod( 'global_sidebar_layout',$default['global_sidebar_layout'] ) ); $default = blog_prime_get_default_theme_options(); $blog_prime_archive_layout = esc_html( get_theme_mod( 'blog_prime_archive_layout',$default['blog_prime_archive_layout'] ) ); $ed_like_dislike = absint( get_theme_mod( 'ed_like_dislike',$default['ed_like_dislike'] ) ); if( is_home() ){ if( $blog_prime_index_layout == 'index-layout-2' ){ if( $home_sidebar_layout == 'no-sidebar' ){ $image_size = 'full'; }else{ $image_size = 'large'; } }else{ $image_size = 'medium_large'; } }else{ if( $blog_prime_archive_layout == 'archive-layout-2' ){ if( $global_sidebar_layout == 'no-sidebar' ){ $image_size = 'full'; }else{ $image_size = 'large'; } }else{ $image_size = 'medium_large'; } } if ( is_singular() ) : ?>