Add generic AJAX functionality

Basic best practices for leveraging WP’s built-in AJAX capability.