converted to the WordPress functions

WordPress has functions for sending back json data in ajax so we should be using those instead of our own rolled ones.
pulled the console.log b/c we don't want it in production
here is the wp json send stuff