Updated web.js and index.html to support response