adding javascript back to the index page