added functions.js and updated index.html to point at functions.js