working version except javascript in index.jsp