%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() ) ); $posted_on = sprintf( /* translators: %s: post date. */ esc_html_x( 'posted on %s', 'post date', 'blogshop' ), '' . $time_string . '' ); echo '' . $posted_on . ''; // WPCS: XSS OK. } endif; if ( ! function_exists( 'blogshop_time' ) ) { function blogshop_time() { $time_string = ''; 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() ) ); echo '' . $time_string . ''; } } if ( ! function_exists( 'blogshop_posted_by' ) ) : /** * Prints HTML with meta information for the current author. */ function blogshop_posted_by() { $byline = sprintf( /* translators: %s: post author. */ esc_html_x( 'by %s', 'post author', 'blogshop' ), '' . esc_html( get_the_author() ) . '' ); echo ' ' . $byline . ''; // WPCS: XSS OK. } endif; if ( ! function_exists( 'blogshop_comment_popuplink' ) ) { function blogshop_comment_popuplink() { comments_popup_link( esc_html__( 'No Comment', 'blogshop' ), esc_html__( '1 Comment', 'blogshop' ), esc_html__( '% Comments', 'blogshop' ) ); } } if ( ! function_exists( 'blogshop_entry_footer' ) ) : /** * Prints HTML with meta information for the categories, tags and comments. */ function blogshop_entry_footer() { // Hide category and tag text for pages. if ( 'post' === get_post_type() ) { /* translators: used between list items, there is a space after the comma */ $categories_list = get_the_category_list( esc_html__( ', ', 'blogshop' ) ); if ( $categories_list ) { /* translators: 1: list of categories. */ printf( '' . esc_html__( 'Posted in %1$s', 'blogshop' ) . '', $categories_list ); // WPCS: XSS OK. } /* translators: used between list items, there is a space after the comma */ $tags_list = get_the_tag_list( '', esc_html_x( 'tags:', 'list item separator', 'blogshop' ) ); if ( $tags_list ) { /* translators: 1: list of tags. */ printf( '' . esc_html__( 'Tagged %1$s', 'blogshop' ) . '', $tags_list ); // WPCS: XSS OK. } } 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', 'blogshop' ), array( 'span' => array( 'class' => array(), ), ) ), get_the_title() ) ); echo ''; } edit_post_link( sprintf( wp_kses( /* translators: %s: Name of current post. Only visible to screen readers */ __( 'Edit %s', 'blogshop' ), array( 'span' => array( 'class' => array(), ), ) ), get_the_title() ), ' ', '' ); } endif; if ( ! function_exists( 'blogshop_post_tag' ) ) { function blogshop_post_tag() { if ( 'post' === get_post_type() ) { /* translators: used between list items, there is a space after the comma */ $categories_list = get_the_category_list( esc_html__( ', ', 'blogshop' ) ); if ( $categories_list ) { /* translators: 1: list of categories. */ printf( '' . esc_html__( 'Posted in %1$s', 'blogshop' ) . '', $categories_list ); // WPCS: XSS OK. } /* translators: used between list items, there is a space after the comma */ $tags_list = get_the_tag_list( '', esc_html_x( ', ', 'list item separator', 'blogshop' ) ); if ( $tags_list ) { /* translators: 1: list of tags. */ printf( '' . esc_html__( 'Tagged %1$s', 'blogshop' ) . '', $tags_list ); // WPCS: XSS OK. } } return; } } if ( ! function_exists( 'blogshop_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 blogshop_post_thumbnail() { $post_thumnail = wp_get_attachment_image_url( get_post_thumbnail_id( get_the_ID() ), 'blogshop-thumbnail' ); if ( has_post_thumbnail() ) : ?> '; else : ?>
term_id); endforeach; endif; $current_post_type = get_post_type($post_id); $query_args = array( 'category__in' => $cat_ids, 'post_type' => $current_post_type, 'post_not_in' => array($post_id), 'posts_per_page' => '4' ); $related_cats_post = new WP_Query( $query_args ); $get_read_more_text = get_theme_mod( 'sub_featured_read_more_text', __( 'Read More', 'blogshop' ) ); if($related_cats_post->have_posts()): echo '
'; while($related_cats_post->have_posts()): $related_cats_post->the_post(); ?>
'; endif; ?>

'; // Restore original Post Data wp_reset_postdata(); endif; } if ( ! function_exists( 'wp_body_open' ) ) : /** * Fire the wp_body_open action. * * Added for backwards compatibility to support pre 5.2.0 WordPress versions. * * @since Twenty Nineteen 1.4 */ function wp_body_open() { /** * Triggered after the opening tag. * * @since Twenty Nineteen 1.4 */ do_action( 'wp_body_open' ); } endif;