1st commit
This commit is contained in:
62
comments.php
Normal file
62
comments.php
Normal file
@@ -0,0 +1,62 @@
|
||||
<?php
|
||||
/*
|
||||
* 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.
|
||||
*/
|
||||
if ( post_password_required() ) {
|
||||
return;
|
||||
}
|
||||
?>
|
||||
<?php if ( comments_open() ) : ?>
|
||||
<!-- If comments are open, but there are no comments. -->
|
||||
|
||||
<div id="comments-wrapper">
|
||||
<div class="comments-content" id="comments">
|
||||
|
||||
<?php if ( have_comments() ) : ?>
|
||||
|
||||
<h3><?php comments_number(__('No Comments', 'toppic'), __('1 Comment', 'toppic'), __('% Comments', 'toppic'));?> </h3>
|
||||
|
||||
<ol class="commentlist">
|
||||
<?php kk_comment_nav(); ?>
|
||||
|
||||
<?php wp_list_comments('type=comment&avatar_size=60&callback=toppic_comment'); ?>
|
||||
|
||||
<?php kk_comment_nav(); ?>
|
||||
</ol>
|
||||
|
||||
<?php else : // this is displayed if there are no comments so far ?>
|
||||
|
||||
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( comments_open() ) : ?>
|
||||
<div class="wrapper" id="form-main">
|
||||
|
||||
<?php
|
||||
$fields = array(
|
||||
'author' => '<ul><li><input type="text" placeholder="Name *" name="author" size="22" tabindex="1" aria-required="true" class="input-name" /></li>',
|
||||
'email' => '<li><input type="text" placeholder="E-mail *" name="email" size="22" tabindex="2" aria-required="true" class="input-email" /></li>',
|
||||
'url' => '<li><input type="text" placeholder="Website" name="url" size="22" tabindex="3" class="input-website" /></li></ul>',
|
||||
);
|
||||
|
||||
$args = array(
|
||||
'fields' => apply_filters( 'comment_form_default_fields', $fields ),
|
||||
'comment_field' => '<textarea name="comment" id="comment" cols="39" rows="4" tabindex="4" class="textarea-comment"></textarea>',
|
||||
'comment_notes_before' => '',
|
||||
'comment_notes_after' => '',
|
||||
'label_submit' => __( 'Submit Comment','toppic' )
|
||||
);
|
||||
|
||||
comment_form($args); ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php else : // comments are closed ?>
|
||||
<!-- If comments are closed. -->
|
||||
|
||||
<?php endif; ?>
|
||||
|
||||
<?php endif; // if you delete this the sky will fall on your head ?>
|
||||
Reference in New Issue
Block a user