How to register and list users based on user roles in WordPress

The idea for this came from a request, where the customer wanted to allow users to register online, and then allow these users to be able to view a list of all other users that have registered. Regular site members, such as subscribers, editors, authors or contributors however should NOT be included, and neither should these (standard WordPress roles) have access to the page that lists these "special" users.

(more…)