- added checks for empty database (fixes #4)
- rearranged some display code in users.php to make it more readable