Updated to do conditional includes of javascript and displays only if data exists.
Fixed dumb omission of bind submit function to save button.