Show special field when correct shipping is chosen
You need to setup the change event on the field: $(‘select.shipping-field’).on(‘change’, function()) { $.post( ajaxurl, { action: ‘shipping_special’, data: ‘your data here..’ }, function(response){ // The response should contain your special field HTML } ); }); You can pass the current shipping select option Then your theme’s functions.php file needs to have the action to … Read more