67 lines
2.1 KiB
PHP
67 lines
2.1 KiB
PHP
<?php
|
|
/**
|
|
* Template part for displaying posts
|
|
*
|
|
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
|
|
*
|
|
* @package CyyWordpress
|
|
*/
|
|
|
|
?>
|
|
|
|
<div id="post-<?php the_ID(); ?>" class="card" style=" margin-bottom: 25px;">
|
|
<div class="card-content">
|
|
<div class="media">
|
|
<div class="media-content">
|
|
|
|
<?php
|
|
if ( is_singular() ) :
|
|
the_title( '<p class="title is-4">', '</p>' );
|
|
else :
|
|
the_title( '<p class="title is-4"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></p>' );
|
|
endif;
|
|
|
|
if ( 'post' === get_post_type() ) :
|
|
?>
|
|
<p class="subtitle is-6">
|
|
<?php
|
|
cyywordpress_posted_on();
|
|
cyywordpress_posted_by();
|
|
?>
|
|
</p><!-- .entry-meta -->
|
|
<?php endif; ?>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="content">
|
|
<?php
|
|
the_content(
|
|
sprintf(
|
|
wp_kses(
|
|
/* translators: %s: Name of current post. Only visible to screen readers */
|
|
// __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'cyywordpress' ),
|
|
__( '继续阅读 <span class="screen-reader-text"> "%s"</span>', 'cyywordpress' ),
|
|
array(
|
|
'span' => array(
|
|
'class' => array(),
|
|
),
|
|
)
|
|
),
|
|
wp_kses_post( get_the_title() )
|
|
)
|
|
);
|
|
|
|
wp_link_pages(
|
|
array(
|
|
'before' => '<div class="page-links">' . esc_html__( 'Pages:', 'cyywordpress' ),
|
|
'after' => '</div>',
|
|
)
|
|
);
|
|
?>
|
|
|
|
<footer class="entry-footer">
|
|
<?php cyywordpress_entry_footer(); ?>
|
|
</footer><!-- .entry-footer -->
|
|
</div>
|
|
</div>
|
|
</div>
|