';
$attachment_navigation .= '
' . esc_html__( 'Previous:', 'knowx' ) . '
';
$attachment_navigation .= $prev_link;
$attachment_navigation .= '
';
}
ob_start();
next_image_link( false );
$next_link = ob_get_clean();
if ( ! empty( $next_link ) ) {
$attachment_navigation .= '';
$attachment_navigation .= '
' . esc_html__( 'Next:', 'knowx' ) . '
';
$attachment_navigation .= $next_link;
$attachment_navigation .= '
';
}
if ( ! empty( $attachment_navigation ) ) {
echo _navigation_markup( $attachment_navigation, $class = 'post-navigation', __( 'Post navigation', 'knowx' ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
}
}
// Show comments only when the post type supports it and when comments are open or at least one comment exists.
if ( post_type_supports( get_post_type(), 'comments' ) && ( comments_open() || get_comments_number() ) ) {
comments_template();
}
}