added login page and auto redirect