PluginProbe
MaxButtons – Create buttons / 6.23
MaxButtons – Create buttons v6.23
6.23 6.24 6.25 6.26 6.26.1 6.27 6.28 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.1.1 7.1.2 7.1.3 7.10 7.11 7.13 7.13.1 7.13.2 7.13.3 All 100 releases
maxbuttons / js / review-notice.js

review-notice.js in MaxButtons – Create buttons 6.23, at js/review-notice.js

44 lines 710 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 jQuery(document).ready(function($) {
2
3 $('.maxbuttons-notice [data-action], .maxbuttons-reviewoffer [data-action]').on('click', mb_review_init_ajax);
4
5 function mb_review_init_ajax (e)
6 {
7 e.preventDefault;
8
9 var new_status = $(e.target).data('action');
10 mb_review_ajax(new_status);
11
12
13
14 }
15
16 function mb_review_ajax(new_status)
17 {
18 var url = mb_ajax_review.ajaxurl;
19 var data = { action: 'set_review_notice_status',
20 status : new_status
21 };
22
23 $.ajax({
24 method: "POST",
25 url: url,
26 data: data,
27 success: function (res)
28 {
29 mb_review_done();
30 },
31
32 });
33
34 }
35
36 function mb_review_done()
37 {
38 $('.maxbuttons-notice, .maxbuttons-reviewoffer').fadeOut();
39
40 }
41
42
43 }); /* END OF JQUERY */
44