I'm attempting to create an API through Wordpress exposing some of my back-end data. I've come to the conclusion that I cannot have a stand alone page (plugin) exposing this data because Wordpress is ...
Here is my wp_enqueue_script and wp_localize_script - which i am using to run an Ajax call. wp_enqueue_script( 'function', plugin_dir_url( __FILE__ ) . 'function.js', array( 'jquery', 'json2' ) ); ...