script.js
15 lines
| 1 | jQuery(document).ready(function($){ |
| 2 | $("#fraudlabspro-woocommerce-notice").click(function(){ |
| 3 | return data={action:"fraudlabspro_woocommerce_admin_notice",fraudlabspro_woocommerce_admin_nonce:fraudlabspro_woocommerce_admin.fraudlabspro_woocommerce_admin_nonce |
| 4 | },$.post(ajaxurl,data),event.preventDefault(),!1 |
| 5 | }); |
| 6 | |
| 7 | $('#button-purge').on('click', function(e) { |
| 8 | if (!confirm('WARNING: All data will be permanently deleted from the local storage (WordPress). It won\'t affect the data kept inside FraudLabs Pro server. Are you sure you want to proceed with the deletion?')) { |
| 9 | e.preventDefault(); |
| 10 | } |
| 11 | else { |
| 12 | $('#form-purge').submit(); |
| 13 | } |
| 14 | }); |
| 15 | }); |