Add CSS minification, AJAX settings, and modern admin styling

This commit is contained in:
Marcus Quinn
2025-03-13 00:30:50 +00:00
parent dc9697e015
commit 77cee1844a
5 changed files with 75 additions and 14 deletions

View File

@ -0,0 +1,14 @@
jQuery(document).ready(function($) {
$('.wpa-superstar-toggle input').on('change', function() {
var option = $(this).attr('name');
var value = $(this).is(':checked') ? 1 : 0;
$.post(ajaxurl, {
action: 'wpa_superstar_update_option',
option: option,
value: value,
nonce: '<?php echo wp_create_nonce( "wpa-superstar-nonce" ); ?>'
}, function(response) {
console.log(response);
});
});
});