updated app.js with serialized form