changed minor logic in index.jsp, added a logout function and more