Advertisement
Guest User

Untitled

a guest
Aug 4th, 2021
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.46 KB | None | 0 0
  1. <?php
  2. /**
  3.  * Template part for displaying posts
  4.  *
  5.  * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
  6.  *
  7.  * @package Yocto
  8.  */
  9.  
  10. ?>
  11.  
  12. <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
  13.  
  14.     <?php
  15.     if ( is_singular() ) : ?>
  16.  
  17.         <header class="entry-header">
  18.             <?php the_title( '<h1 class="entry-title">', '</h1>hfghfghf' ); ?>
  19.         </header>
  20.  
  21.         <div class="entry-content">
  22.             <?php
  23.                 get_template_part( 'template-parts/entry-meta' );
  24.                
  25.                 the_content();
  26.                 get_template_part( 'template-parts/template-autorenbox' ); /** Autorenbox */
  27.                 get_template_part( 'template-parts/template-related-posts-blog' ); /** Related Posts */
  28.             ?>
  29.         </div><!-- .entry-content -->
  30.        
  31.         <?php get_template_part( 'template-parts/entry-footer' ); ?>
  32.         <?php
  33.     else : ?>
  34.  
  35.         <header class="entry-header">
  36.             <?php
  37.                 if ( is_sticky() && is_home() ) :
  38.                     echo yocto_get_svg( array( 'icon' => 'pin' ) );
  39.                 endif;
  40.                 the_title( '<h2 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h2>' );
  41.             ?>
  42.         </header>
  43.  
  44.         <div class="entry-content">
  45.             <?php
  46.                 get_template_part( 'template-parts/entry-meta' );
  47.                 yocto_post_thumbnail();
  48.                 the_excerpt();
  49.                 wp_link_pages( array(
  50.                     'before' => '<div class="page-links">' . esc_html__( 'Pages:', 'yocto' ),
  51.                     'after'  => '</div>',
  52.                 ) );
  53.             ?>
  54.         </div>
  55.         <?php
  56.     endif; // End check single. ?>
  57.  
  58. </article><!-- #post-## -->
  59.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement