Modified controller and index.html