updated web.js
added index, changed input