-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdelete.php
More file actions
66 lines (36 loc) · 1.38 KB
/
delete.php
File metadata and controls
66 lines (36 loc) · 1.38 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<?php
include("../../../wp-blog-header.php");
status_header(200);
nocache_headers();
/*
QUESTO FILE CANCELLA L'INDIRIZZO EMAIL DALLA LISTA
*/
function CancellaEmail() {
global $_GET;
global $wpdb;
$table_email = $wpdb->prefix . "nl_email";
if($_GET['action']=="delete"):
$user_count = $wpdb->get_var("SELECT COUNT(*) FROM $table_email where magic_string ='$_GET[c]';");
if($user_count<1) :
echo "<div class=\"error\">".__('email addresso not present or something is going wrong?!', 'sendit')."</div>";
else :
$wpdb->query("UPDATE $table_email set accepted='d' where magic_string = '$_GET[c]'");
$table_liste = $wpdb->prefix . "nl_liste";
$templaterow=$wpdb->get_row("SELECT * from $table_liste where id_lista = '$_GET[lista]' ");
//utile anzi fondamentale
$plugindir = "sendit/";
$sendit_root = get_option('siteurl') . '/wp-content/plugins/'.$plugindir;
/*
* QUI potete ridisegnare il vs TEMA
*/
get_header();
echo '<div id=\"content\">';
echo '<div id="message" class="updated fade"><p><strong>'.__("Your email address was deleted suffesfully from our mailing list!", "sendit").'</strong></p></div>';
echo '</div>';
echo '</div>';
get_footer();
endif;
endif;
}
CancellaEmail();
?>