PluginProbe
SendWP / 1.2.7
SendWP v1.2.7
trunk 0.0.1 0.0.2 0.0.3 1.0.0 1.0.1 1.0.2 1.0.3 1.0.4 1.1 1.2.10 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 1.3 1.3.1 1.4.4 1.4.5 1.4.6 1.4.8
sendwp / assets / js / admin / settings.js

settings.js in SendWP 1.2.7, at assets/js/admin/settings.js

51 lines 2.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 jQuery(document).ready(
2 function () {
3 jQuery('#spoiler-title').click(
4 function () {
5 if(jQuery('#spoiler-content').hasClass('closed') ) {
6 jQuery('#spoiler-content').removeClass('closed');
7 jQuery('#spoiler-content').addClass('open');
8 jQuery('#spoiler-arrow').removeClass('down');
9 jQuery('#spoiler-arrow').addClass('up');
10 } else {
11 jQuery('#spoiler-content').removeClass('open');
12 jQuery('#spoiler-content').addClass('closed');
13 jQuery('#spoiler-arrow').removeClass('up');
14 jQuery('#spoiler-arrow').addClass('down');
15 }
16 }
17 );
18
19 jQuery('#sendwp-enabled-checkbox').change(
20 function () {
21 if(jQuery('#sendwp-enabled-checkbox').is(':checked') ) {
22 jQuery('#sendwp-enabled-status').html(sendwpAdmin.loading);
23 var data = {
24 action: 'sendwp_forwarding',
25 sendwp_forwarding: 'enable',
26 security: sendwpAdmin.ajaxNonce
27 };
28 jQuery.post(
29 ajaxurl, data, function ( response ) {
30 var response = JSON.parse(response);
31 jQuery('#sendwp-enabled-status').html(sendwpAdmin.enabled);
32 }
33 );
34 } else {
35 jQuery('#sendwp-enabled-status').html(sendwpAdmin.loading);
36 var data = {
37 action: 'sendwp_forwarding',
38 sendwp_forwarding: 'disable',
39 security: sendwpAdmin.ajaxNonce
40 };
41 jQuery.post(
42 ajaxurl, data, function ( response ) {
43 var response = JSON.parse(response);
44 jQuery('#sendwp-enabled-status').html(sendwpAdmin.disabled);
45 }
46 );
47 }
48 }
49 );
50 }
51 );