PluginProbe
UsersWP – Front-end login form, User Registration, User Profile & Members Directory plugin for WP / 1.2.43
UsersWP – Front-end login form, User Registration, User Profile & Members Directory plugin for WP v1.2.43
1.2.72 1.2.71 1.2.70 1.2.69 1.2.68 1.2.67 1.2.66 1.2.65 1.2.64 1.2.63 trunk 1.0.10 1.0.11 1.0.12 1.0.13 1.0.14 1.0.15 1.0.16 1.0.17 1.0.18 1.0.19 1.0.20 1.0.21 1.0.22 1.0.23 All 172 releases
userswp / templates / loop-comments.php

loop-comments.php in UsersWP – Front-end login form, User Registration, User Profile & Members Directory plugin for WP 1.2.43, at templates/loop-comments.php

33 lines 913 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 if ( ! defined( 'ABSPATH' ) ) {
4 exit; // Exit if accessed directly
5 }
6
7 $the_query = isset( $args['template_args']['the_query'] ) ? $args['template_args']['the_query'] : '';
8 $maximum_pages = isset( $args['template_args']['maximum_pages'] ) ? $args['template_args']['maximum_pages'] : '';
9 $title = isset( $args['template_args']['title'] ) ? $args['template_args']['title'] : __('Comments', 'userswp');
10 ?>
11 <h3><?php echo esc_attr( $title );?></h3>
12
13 <div class="uwp-profile-item-block">
14 <?php
15 // The Loop
16 if ($the_query) {
17 echo '<ul class="uwp-profile-item-ul">';
18 foreach ( $the_query as $comment ) {
19 $args['template_args']['comment'] = $comment;
20 uwp_get_template("comments-item.php", $args);
21 ?>
22
23 <?php
24 }
25 echo '</ul>';
26 } else {
27 // no comments found
28 echo "<p>".esc_html__('No comments found', 'userswp')."</p>";
29 }
30
31 do_action('uwp_profile_pagination', $maximum_pages);
32 ?>
33 </div>