Sorting json data by username, index check for logged in users, styling