forked from mobilizetoday/wordpress-jquerymobile
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcomments.php
executable file
·38 lines (26 loc) · 1015 Bytes
/
comments.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php
if ( post_password_required() ) { ?>
This post is password protected. Enter the password to view comments.
<?php
return;
}
?>
<?php if ( have_comments() ) : ?>
<h2 id="comments"><?php comments_number('No Responses', 'One Response', '% Responses' );?></h2>
<ul class="commentlist" data-role="listview" data-inset="true"<?php jqmobile_ui('comment');?>>
<?php wp_list_comments( array( 'max_depth' => 1, 'callback' => 'jquerymobile_comment' ) ); ?>
</ul>
<div class="navigation" data-role="controlgroup">
<div class="next-posts"><?php previous_comments_link() ?></div>
<div class="prev-posts"><?php next_comments_link() ?></div>
</div>
<?php else : // this is displayed if there are no comments so far ?>
<?php if ( comments_open() ) : ?>
<!-- If comments are open, but there are no comments. -->
<?php else : // comments are closed ?>
<p>Comments are closed.</p>
<?php endif; ?>
<?php endif; ?>
<?php if ( comments_open() ) : ?>
<?php comment_form(); ?>
<?php endif; ?>