jQuery(document).ready(function ($) {
    // When the notice is dismissed
    $(document).on('click', '.disinfection-notice .notice-dismiss', function () {
        $.post(ajaxurl, {
            action: 'disinfection_dismiss_notice'
        });
    });
});