fixed the javascript not being displayed on main page