migrated the saveData function from jquery to angular. I needed to change $_POST to $_REQUEST to make angular's ajax work. Simplified the "success" return so it's just a string instead of JSON.