All users in the site map
-
Hi!
Could not find a plugin function that allows you to display all registered users in the site map.A temporary solution changed the sql query:
$sql = "SELECT DISTINCT u.ID, u.user_nicename, MAX(p.post_modified_gmt) AS last_post FROM {$wpdb->users} u, {$wpdb->posts} p WHERE p.post_author = u.ID AND p.post_status = 'publish' AND p.post_type = 'post' AND p.post_password = '' " . (floatval($wp_version) < 2.1?"AND p.post_date_gmt <= '" . gmdate('Y-m-d H:i:59') . "'":"") . " GROUP BY u.ID, u.user_nicename";this
$sql = " SELECT ID, user_nicename, user_registered AS last_post FROM wp_users ";it works, but when you update the plugin code will fly. Please add the plugin can display all users.
Thank you.
The topic ‘All users in the site map’ is closed to new replies.