Edit File by line
/home/barbar84/public_h.../wp-conte.../themes/twentytw.../template...
File: navigation.php
<?php
[0] Fix | Delete
/**
[1] Fix | Delete
* Displays the next and previous post navigation in single posts.
[2] Fix | Delete
*
[3] Fix | Delete
* @package WordPress
[4] Fix | Delete
* @subpackage Twenty_Twenty
[5] Fix | Delete
* @since Twenty Twenty 1.0
[6] Fix | Delete
*/
[7] Fix | Delete
[8] Fix | Delete
$next_post = get_next_post();
[9] Fix | Delete
$prev_post = get_previous_post();
[10] Fix | Delete
[11] Fix | Delete
if ( $next_post || $prev_post ) {
[12] Fix | Delete
[13] Fix | Delete
$pagination_classes = '';
[14] Fix | Delete
[15] Fix | Delete
if ( ! $next_post ) {
[16] Fix | Delete
$pagination_classes = ' only-one only-prev';
[17] Fix | Delete
} elseif ( ! $prev_post ) {
[18] Fix | Delete
$pagination_classes = ' only-one only-next';
[19] Fix | Delete
}
[20] Fix | Delete
[21] Fix | Delete
?>
[22] Fix | Delete
[23] Fix | Delete
<nav class="pagination-single section-inner<?php echo esc_attr( $pagination_classes ); ?>" aria-label="<?php esc_attr_e( 'Post', 'twentytwenty' ); ?>" role="navigation">
[24] Fix | Delete
[25] Fix | Delete
<hr class="styled-separator is-style-wide" aria-hidden="true" />
[26] Fix | Delete
[27] Fix | Delete
<div class="pagination-single-inner">
[28] Fix | Delete
[29] Fix | Delete
<?php
[30] Fix | Delete
if ( $prev_post ) {
[31] Fix | Delete
?>
[32] Fix | Delete
[33] Fix | Delete
<a class="previous-post" href="<?php echo esc_url( get_permalink( $prev_post->ID ) ); ?>">
[34] Fix | Delete
<span class="arrow" aria-hidden="true">&larr;</span>
[35] Fix | Delete
<span class="title"><span class="title-inner"><?php echo wp_kses_post( get_the_title( $prev_post->ID ) ); ?></span></span>
[36] Fix | Delete
</a>
[37] Fix | Delete
[38] Fix | Delete
<?php
[39] Fix | Delete
}
[40] Fix | Delete
[41] Fix | Delete
if ( $next_post ) {
[42] Fix | Delete
?>
[43] Fix | Delete
[44] Fix | Delete
<a class="next-post" href="<?php echo esc_url( get_permalink( $next_post->ID ) ); ?>">
[45] Fix | Delete
<span class="arrow" aria-hidden="true">&rarr;</span>
[46] Fix | Delete
<span class="title"><span class="title-inner"><?php echo wp_kses_post( get_the_title( $next_post->ID ) ); ?></span></span>
[47] Fix | Delete
</a>
[48] Fix | Delete
<?php
[49] Fix | Delete
}
[50] Fix | Delete
?>
[51] Fix | Delete
[52] Fix | Delete
</div><!-- .pagination-single-inner -->
[53] Fix | Delete
[54] Fix | Delete
<hr class="styled-separator is-style-wide" aria-hidden="true" />
[55] Fix | Delete
[56] Fix | Delete
</nav><!-- .pagination-single -->
[57] Fix | Delete
[58] Fix | Delete
<?php
[59] Fix | Delete
}
[60] Fix | Delete
[61] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function