why is my wordpress Jquery-Ajax call not working?
You need to change the data that you are sending in the ajax request. For ajax to work in WordPress you need to send the action variable in ajax post request. Change data: {package: package}, to data: {action: ‘ajaxAutopopulate’, package: package} Also you can use the wordpress default function wp_send_json( $response ) for encoding of … Read more