Added login JS to index