$perPage, "status" => "all", "user_id" => "", "author_email" => ""]; if ($currentUserId) { $args["user_id"] = $currentUserId; } else if ($currentUserEmail) { $args["author_email"] = $currentUserEmail; } if ($args["user_id"] || $args["author_email"]) { $items = get_comments($args); if ($items && is_array($items)) { $args["number"] = null; $args["count"] = true; $itemsCount = get_comments($args); $pCount = intval($itemsCount / $perPage); $pageCount = ($itemsCount % $perPage == 0) ? $pCount : $pCount + 1; $page = 0; foreach ($items as $k => $item) { include WPDISCUZ_DIR_PATH . "/utils/layouts/activity/item.php"; } include WPDISCUZ_DIR_PATH . "/utils/layouts/pagination.php"; ?>