HEX
Server: Apache/2.4.41 (Ubuntu)
System: Linux vmi1674223.contaboserver.net 5.4.0-182-generic #202-Ubuntu SMP Fri Apr 26 12:29:36 UTC 2024 x86_64
User: root (0)
PHP: 7.4.3-4ubuntu2.22
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/Application/wp-content/themes/zoomy/comments.php
<?php
/**
 * The template for displaying comments
 *
 * This is the template that displays the area of the page that contains both the current comments
 * and the comment form.
 *
 * @link https://codex.wordpress.org/Template_Hierarchy
 *
 * @package zoomy
 */

/*
 * If the current post is protected by a password and
 * the visitor has not yet entered the password we will
 * return early without loading the comments.
 */
$opt                    = get_option( 'zoomy_opt' );
$is_single_post_meta    = isset( $opt['is_single_post_meta'] ) ? $opt['is_single_post_meta'] : '1';
$is_single_comment_meta = isset( $opt['is_single_comment_meta'] ) ? $opt['is_single_comment_meta'] : '1';

if ( is_single() ) {
	$form_spacer        = have_comments() ? 'mt-0' : 'mt-55';
}

if ( post_password_required() ) {
	return;
}

if ( have_comments() ) :

	if ( $is_single_post_meta == '1' && $is_single_comment_meta == '1' ) : ?>
        <div class="row mt-55 mb-2">
            <div class="col-lg-12 text-left">
                <h4 class="comment-section-heading">
                    <?php zoomy_comment_count( get_the_ID() ) ?>
                </h4>
            </div>
        </div>
	<?php endif; ?>

    <div class="comments-area">
        <ul class="latest-commmnet">
			<?php
			wp_list_comments(
				array(
					'style'      => 'ul',
					'short_ping' => true,
					'walker'     => new Zoomy_Walker_Comment,
				)
			);
			the_comments_navigation();
			?>
        </ul>
    </div>

<?php endif; ?>

<div class="comments-form-area mb-xl-0 mb-lg-0 mb-md-80 mb-xs-80 <?php echo esc_attr( $form_spacer ); ?>">
	<?php if ( ! comments_open() && get_comments_number() && post_type_supports( get_post_type(), 'comments' ) ) : ?>
        <div class="row">
            <div class="col-lg-12 text-center mb-40">
                <p class="no-comments alert alert-warning"><?php esc_html_e( 'Comments are closed.', 'zoomy' ); ?></p>
            </div>
        </div>
	<?php endif;

	$commenter     = wp_get_current_commenter();
	$req           = get_option( 'require_name_email' );
	$aria_req      = ( $req ? " aria-required='true'" : '' );
	$consent       = empty( $commenter['comment_author_email'] ) ? '' : ' checked="checked"';
	$fields        = array(
		'author'   => '<div class="col-lg-6 mb-20"><input type="text" placeholder="' . esc_attr__( "Your name", "zoomy" ) . '" name="author" id="name" value="' . esc_attr( $commenter['comment_author'] ) . '" ' . $aria_req . '>' . '</div>',
		'email'    => '<div class="col-lg-6 mb-20"> <input type="email" placeholder="' . esc_attr__( "Your email", "zoomy" ) . '" name="email" value="' . esc_attr( $commenter['comment_author_email'] ) . '" ' . $aria_req . '>' . '</div>',
		'url'      => '',
		'cookies'  => '<p class="comment-form-cookies-consent"><input id="wp-comment-cookies-consent" name="wp-comment-cookies-consent" type="checkbox" value="yes"' . $consent . ' />' .
		             '<label for="wp-comment-cookies-consent">' . esc_html__( "Save my name and email in this browser for the next time I comment.", "zoomy" ) . '</label></p>'
	);
	$comments_args = array(
		'fields'               => apply_filters( 'comment_form_default_fields', $fields ),
		'class_form'           => 'row comments-form',
		'class_submit'         => 'theme_btn comment_btn',
		'title_reply_before'   => '<h2>',
		'title_reply'          => esc_html__( 'Leave a comment', 'zoomy' ),
		'title_reply_after'    => '</h2>',
		'comment_notes_before' => '<p class="comment-short-insturction">' . esc_html__( "Sign in to post your comment or sine up if you dont have any account.", "zoomy" ) . '</p>',
		'comment_field'        => '<div class="col-lg-12 mb-20"><textarea placeholder="' . esc_attr__( "Write Your Comment", "zoomy" ) . '" cols="30" rows="10" name="comment" id="comment"></textarea></div>',
		'comment_notes_after'  => '',
	);
	comment_form( $comments_args ); ?>
</div>