Added return statments to responses. Improved error messages
Fixed DOM elements and jQuery scripts