PluginProbe
Insert PHP Code Snippet / 1.2.5
Insert PHP Code Snippet v1.2.5
1.4.7 1.3.3 1.3.4 1.3.5 1.3.6 1.3.7 1.3.8 1.4 1.4.1 1.4.2 1.4.3 1.4.4 1.4.5 1.4.6 trunk 1.0 1.1 1.2 1.2.1 1.2.2 1.2.3 1.2.4 1.2.5 1.2.6 1.3 All 27 releases
insert-php-code-snippet / ajax-handler.php

ajax-handler.php in Insert PHP Code Snippet 1.2.5, at ajax-handler.php

24 lines 597 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 if ( ! defined( 'ABSPATH' ) )
3 exit;
4
5 add_action('wp_ajax_ips_backlink', 'xyz_ips_ajax_backlink');
6 function xyz_ips_ajax_backlink() {
7
8 check_ajax_referer('xyz-ips-blink','security');
9 if(current_user_can('administrator')){
10 global $wpdb;
11 if(isset($_POST)){
12 if(intval($_POST['enable'])==1){
13 update_option('xyz_credit_link','ips');
14 echo 1;
15 }
16 if(intval($_POST['enable'])==-1){
17 update_option('xyz_ips_credit_dismiss','dis');
18 echo -1;
19 }
20 }
21 }die;
22 }
23
24 ?>