%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 = '' . $time_string . ''; echo '' . $posted_on . ''; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped } endif; if ( ! function_exists( 'botiga_posted_by' ) ) : /** * Prints HTML with meta information for the current author. */ function botiga_posted_by() { global $post; $author = $post->post_author; $show_avatar = get_theme_mod( 'show_avatar', 0 ); $byline = ''; if ( $show_avatar ) { $byline .= get_avatar( get_the_author_meta( 'email', $author ) , 16 ); } $byline .= '' . esc_html( get_the_author() ) . ''; echo ' ' . $byline . ''; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped } endif; if ( ! function_exists( 'botiga_post_categories' ) ) : function botiga_post_categories() { 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__( ', ', 'botiga' ) ); if ( $categories_list ) { /* translators: 1: list of categories. */ printf( '' . '%1$s' . '', $categories_list ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped } } } endif; if ( ! function_exists( 'botiga_entry_comments' ) ) : function botiga_entry_comments() { if ( ! post_password_required() && ( comments_open() || get_comments_number() ) ) { echo ''; comments_popup_link( esc_html__( '0 comments', 'botiga' ), esc_html__( '1 comment', 'botiga' ), esc_html__( '% comments', 'botiga' ) ); echo ''; } } endif; if ( ! function_exists( 'botiga_entry_footer' ) ) : /** * Prints HTML with meta information for the categories, tags and comments. */ function botiga_entry_footer() { $single_post_show_tags = get_theme_mod( 'single_post_show_tags', 1 ); if ( !$single_post_show_tags ) { return; } // Hide category and tag text for pages. if ( 'post' === get_post_type() ) { /* translators: used between list items, there is a space after the comma */ $tags_list = get_the_tag_list( '' ); if ( $tags_list ) { /* translators: 1: list of tags. */ printf( '' . esc_html__( 'Tagged %1$s', 'botiga' ) . '', $tags_list ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped } } edit_post_link( sprintf( wp_kses( /* translators: %s: Name of current post. Only visible to screen readers */ __( 'Edit %s', 'botiga' ), array( 'span' => array( 'class' => array(), ), ) ), wp_kses_post( get_the_title() ) ), '', '' ); } endif; if ( ! function_exists( 'botiga_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 botiga_post_thumbnail() { if ( post_password_required() || is_attachment() || ! has_post_thumbnail() ) { return; } if ( is_singular() ) : ?>
'; foreach( $elements as $element ) { call_user_func( $element ); } echo ''; } endif; /** * Single post navigation */ function botiga_single_post_navigation() { $single_post_show_post_nav = get_theme_mod( 'single_post_show_post_nav', 1 ); if ( !$single_post_show_post_nav ) { return; } the_post_navigation( array( 'prev_text' => '' . esc_html__( 'Previous:', 'botiga' ) . ' %title', 'next_text' => '' . esc_html__( 'Next:', 'botiga' ) . ' %title', ) ); } add_action( 'botiga_after_single_post_content', 'botiga_single_post_navigation', 11 ); /** * Post author bio */ function botiga_post_author_bio() { $single_post_show_author_box = get_theme_mod( 'single_post_show_author_box', 0 ); if ( !$single_post_show_author_box ) { return; } ?>

term_id ); endforeach; endif; $query_args = array( 'category__in' => $cat_ids, 'post__not_in' => array( $post_id ), 'posts_per_page' => '3', ); $related_cats_post = new WP_Query( $query_args ); if( $related_cats_post->have_posts()) : echo '