Version Description
FIXED: Email automatic plugin update notification to admin sometimes still send out.
Download this release
Release Info
Developer | Virgial |
Plugin | Manage Notification E-mails |
Version | 1.6.1 |
Comparing to | |
See all releases |
Code changes from version 1.7.0 to 1.6.1
- core/class.FAMNE.php +0 -190
- core/functions.setup.php +0 -16
- includes/class.FAMNE.php +117 -0
- includes/class.FAMNESettingsPage.php +322 -0
- {modules/pluggable → includes}/pluggable-functions-1.2.php +0 -0
- {modules/pluggable → includes}/pluggable-functions-1.3.php +0 -0
- includes/pluggable-functions-1.4.php +329 -0
- {modules/pluggable → includes}/pluggable-functions-1.5.php +6 -11
- includes/pluggable-functions.php +213 -0
- languages/manage-notification-emails-nl_NL.mo +0 -0
- languages/manage-notification-emails-nl_NL.po +80 -211
- languages/manage-notification-emails.pot +51 -186
- manage-notification-emails.php +23 -20
- modules/custom-recipients.php +0 -88
- modules/pluggable/pluggable.php +0 -17
- modules/settings-page/assets/main.min.css +0 -3
- modules/settings-page/assets/main.min.css.map +0 -1
- modules/settings-page/assets/main.min.js +0 -2
- modules/settings-page/assets/main.min.js.map +0 -1
- modules/settings-page/class.FAMNESettingsPage.php +0 -211
- modules/settings-page/formfields.php +0 -39
- modules/settings-page/settings-page.php +0 -33
- modules/settings-page/views/container.php +0 -35
- modules/settings-page/views/extra.php +0 -21
- modules/settings-page/views/modules.php +0 -15
- modules/settings-page/views/settings.php +0 -47
- modules/settings-page/views/sidebar.php +0 -0
- modules/user-email-changed.php +0 -117
- readme.txt +2 -2
- screen-1.png +0 -0
- screenshot-1.png +0 -0
- screenshot-2.png +0 -0
core/class.FAMNE.php
DELETED
@@ -1,190 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Manage notification emails settings page class
|
4 |
-
*
|
5 |
-
* initializes the plugin.
|
6 |
-
*
|
7 |
-
* This file is part of the Manage Notification Emails plugin
|
8 |
-
* You can find out more about this plugin at https://www.freeamigos.nl
|
9 |
-
* Copyright (c) 2006-2015 Virgial Berveling
|
10 |
-
*
|
11 |
-
* @package WordPress
|
12 |
-
* @author Virgial Berveling
|
13 |
-
* @copyright 2006-2015
|
14 |
-
*
|
15 |
-
* since: 1.6.0
|
16 |
-
*/
|
17 |
-
|
18 |
-
if (!class_exists('FAMNE')):
|
19 |
-
class FAMNE{
|
20 |
-
|
21 |
-
private static $modules = array();
|
22 |
-
private static $notices = array();
|
23 |
-
|
24 |
-
public function __construct($modules=false)
|
25 |
-
{
|
26 |
-
add_action('init',array($this,'do_modules'));
|
27 |
-
add_action( 'admin_footer', array($this,'admin_notices') );
|
28 |
-
|
29 |
-
}
|
30 |
-
|
31 |
-
static function AddModule($name,$args)
|
32 |
-
{
|
33 |
-
self::$modules[$name] = (object) array(
|
34 |
-
'name' => isset($args['name'])?$args['name']:$name,
|
35 |
-
'version' => isset($args['version'])?$args['version']:FA_MNE_VERSION,
|
36 |
-
'licensed' => isset($args['licensed'])?true:false,
|
37 |
-
'slug' => isset($args['slug'])?$args['slug']:$name,
|
38 |
-
'card' => isset($args['card'])?$args['card']:null,
|
39 |
-
'option_id' =>isset($args['option_id'])?$args['option_id']:null,
|
40 |
-
);
|
41 |
-
}
|
42 |
-
|
43 |
-
static function getModules()
|
44 |
-
{
|
45 |
-
return self::$modules;
|
46 |
-
}
|
47 |
-
|
48 |
-
|
49 |
-
static function AddNotice($message='missing notification message', $priority='error',$dismissible=false)
|
50 |
-
{
|
51 |
-
self::$notices[] = array('message'=>$message, 'priority'=>$priority, 'dismissible'=>$dismissible );
|
52 |
-
}
|
53 |
-
|
54 |
-
public function admin_notices()
|
55 |
-
{
|
56 |
-
while (is_array(self::$notices) && count(self::$notices)>0):
|
57 |
-
$notice = array_pop(self::$notices);
|
58 |
-
$dismissible = $notice['dismissible']?' is-dismissible':'';
|
59 |
-
printf( '<div class="%1$s"><p>%2$s</p></div>', 'notice notice-'.$notice['priority'].$dismissible, $notice['message'] );
|
60 |
-
endwhile;
|
61 |
-
}
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
/**
|
66 |
-
* @since 2.0.1
|
67 |
-
* added folder namespacing
|
68 |
-
*/
|
69 |
-
|
70 |
-
public function do_modules()
|
71 |
-
{
|
72 |
-
do_action('fa_mne_modules');
|
73 |
-
}
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
static public function get_option($name)
|
78 |
-
{
|
79 |
-
if ($name == 'fa_mne_version') return get_site_option($name);
|
80 |
-
|
81 |
-
return get_option($name);
|
82 |
-
}
|
83 |
-
|
84 |
-
static public function update_option($name,$options)
|
85 |
-
{
|
86 |
-
if ($name == 'fa_mne_version') return update_site_option($name,$options);
|
87 |
-
|
88 |
-
return update_option($name,$options);
|
89 |
-
}
|
90 |
-
|
91 |
-
static public function default_options()
|
92 |
-
{
|
93 |
-
return array(
|
94 |
-
'wp_new_user_notification_to_user' => '1',
|
95 |
-
'wp_new_user_notification_to_admin' => '1',
|
96 |
-
'wp_notify_postauthor' => '1',
|
97 |
-
'wp_notify_moderator' => '1',
|
98 |
-
'wp_password_change_notification' => '1',
|
99 |
-
'send_password_change_email' => '1',
|
100 |
-
'send_email_change_email' => '1',
|
101 |
-
'send_password_forgotten_email' => '1',
|
102 |
-
'send_password_admin_forgotten_email' => '1',
|
103 |
-
'auto_core_update_send_email' => '1',
|
104 |
-
'auto_plugin_update_send_email' => '1',
|
105 |
-
'auto_theme_update_send_email' => '1'
|
106 |
-
);
|
107 |
-
}
|
108 |
-
|
109 |
-
static public function update_check()
|
110 |
-
{
|
111 |
-
if (self::get_option( 'fa_mne_version' ) != FA_MNE_VERSION) {
|
112 |
-
$options = self::get_option( 'famne_options' );
|
113 |
-
$current_version = self::get_option( 'fa_mne_version' );
|
114 |
-
|
115 |
-
/* Is this the first install, then set all defaults to active */
|
116 |
-
if ($options === false)
|
117 |
-
{
|
118 |
-
self::install();
|
119 |
-
return;
|
120 |
-
}
|
121 |
-
|
122 |
-
if ( version_compare($current_version, '1.5.1') <=0)
|
123 |
-
{
|
124 |
-
/** update to 1.6.0
|
125 |
-
* setting the newly added options to checked as default
|
126 |
-
*/
|
127 |
-
$options['auto_plugin_update_send_email'] = '1';
|
128 |
-
$options['auto_theme_update_send_email'] = '1';
|
129 |
-
self::update_option('famne_options',$options);
|
130 |
-
}
|
131 |
-
|
132 |
-
if ($current_version == '1.1.0')
|
133 |
-
{
|
134 |
-
/** update 1.1.0 to 1.2.0
|
135 |
-
* setting the newly added options to checked as default
|
136 |
-
*/
|
137 |
-
|
138 |
-
$options['send_password_forgotten_email'] = '1';
|
139 |
-
$options['send_password_admin_forgotten_email'] ='1';
|
140 |
-
|
141 |
-
self::update_option('famne_options',$options);
|
142 |
-
}
|
143 |
-
|
144 |
-
|
145 |
-
/** update to 1.4.1
|
146 |
-
* setting the newly added options to checked as default
|
147 |
-
*/
|
148 |
-
|
149 |
-
if ( version_compare($current_version, '1.4.0') <=0)
|
150 |
-
{
|
151 |
-
$options['auto_core_update_send_email'] ='1';
|
152 |
-
self::update_option('famne_options',$options);
|
153 |
-
}
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
/** update 1.0 to 1.1 fix:
|
158 |
-
* update general wp_new_user_notification option into splitted options
|
159 |
-
*/
|
160 |
-
if ( version_compare($current_version, '1.0.0') <=0)
|
161 |
-
{
|
162 |
-
unset($options['wp_new_user_notification']);
|
163 |
-
$options['wp_new_user_notification_to_user'] ='1';
|
164 |
-
$options['wp_new_user_notification_to_admin'] ='1';
|
165 |
-
self::update_option('famne_options',$options);
|
166 |
-
}
|
167 |
-
|
168 |
-
/* UPDATE DONE! */
|
169 |
-
self::update_option('fa_mne_version',FA_MNE_VERSION);
|
170 |
-
}
|
171 |
-
}
|
172 |
-
|
173 |
-
|
174 |
-
static public function install()
|
175 |
-
{
|
176 |
-
$famne_options = self::default_options();
|
177 |
-
self::update_option('famne_options',$famne_options);
|
178 |
-
self::update_option('fa_mne_version',FA_MNE_VERSION);
|
179 |
-
}
|
180 |
-
|
181 |
-
static public function uninstall()
|
182 |
-
{
|
183 |
-
delete_site_option('fa_mne_version');
|
184 |
-
delete_site_option('famne_options');
|
185 |
-
delete_option('fa_mne_version');
|
186 |
-
delete_option('famne_options');
|
187 |
-
}
|
188 |
-
|
189 |
-
}
|
190 |
-
endif;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
core/functions.setup.php
DELETED
@@ -1,16 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if (class_exists('FAMNE')&& !function_exists ( 'famne_meta_links') ):
|
3 |
-
|
4 |
-
function famne_meta_links( $links, $file )
|
5 |
-
{
|
6 |
-
if ( $file === 'manage-notification-emails/manage-notification-emails.php' )
|
7 |
-
{
|
8 |
-
$links[] = '<a href="https://paypal.me/virgial/5" target="_blank" title="'.__('Donate').'"><strong>'.__('Donate').'</strong> <span class="dashicons dashicons-coffee"></span></a>';
|
9 |
-
}
|
10 |
-
return $links;
|
11 |
-
}
|
12 |
-
|
13 |
-
add_filter( 'plugin_row_meta', 'famne_meta_links', 10, 2 );
|
14 |
-
|
15 |
-
endif;
|
16 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/class.FAMNE.php
ADDED
@@ -0,0 +1,117 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Manage notification emails settings page class
|
4 |
+
*
|
5 |
+
* initializes the plugin.
|
6 |
+
*
|
7 |
+
* This file is part of the Manage Notification Emails plugin
|
8 |
+
* You can find out more about this plugin at http://www.freeamigos.mx
|
9 |
+
* Copyright (c) 2006-2015 Virgial Berveling
|
10 |
+
*
|
11 |
+
* @package WordPress
|
12 |
+
* @author Virgial Berveling
|
13 |
+
* @copyright 2006-2015
|
14 |
+
*
|
15 |
+
* since: 1.6.0
|
16 |
+
*/
|
17 |
+
|
18 |
+
if (!class_exists('FAMNE')):
|
19 |
+
class FAMNE{
|
20 |
+
|
21 |
+
static public function get_option($name)
|
22 |
+
{
|
23 |
+
if ($name == 'fa_mne_version') return get_site_option($name);
|
24 |
+
|
25 |
+
return get_option($name);
|
26 |
+
}
|
27 |
+
|
28 |
+
static public function update_option($name,$options)
|
29 |
+
{
|
30 |
+
if ($name == 'fa_mne_version') return update_site_option($name,$options);
|
31 |
+
|
32 |
+
return update_option($name,$options);
|
33 |
+
|
34 |
+
}
|
35 |
+
static public function update_check()
|
36 |
+
{
|
37 |
+
if (self::get_option( 'fa_mne_version' ) != FA_MNE_VERSION) {
|
38 |
+
$options = self::get_option( 'famne_options' );
|
39 |
+
$current_version = self::get_option( 'fa_mne_version' );
|
40 |
+
|
41 |
+
/* Is this the first install, then set all defaults to active */
|
42 |
+
if ($options === false)
|
43 |
+
{
|
44 |
+
$options = array(
|
45 |
+
'wp_new_user_notification_to_user' => '1',
|
46 |
+
'wp_new_user_notification_to_admin' => '1',
|
47 |
+
'wp_notify_postauthor' => '1',
|
48 |
+
'wp_notify_moderator' => '1',
|
49 |
+
'wp_password_change_notification' => '1',
|
50 |
+
'send_password_change_email' => '1',
|
51 |
+
'send_email_change_email' => '1',
|
52 |
+
'send_password_forgotten_email' => '1',
|
53 |
+
'send_password_admin_forgotten_email' => '1',
|
54 |
+
'auto_core_update_send_email' => '1',
|
55 |
+
'auto_plugin_update_send_email' => '1',
|
56 |
+
'auto_theme_update_send_email' => '1'
|
57 |
+
);
|
58 |
+
|
59 |
+
self::update_option('famne_options',$options);
|
60 |
+
|
61 |
+
/* UPDATE DONE! */
|
62 |
+
self::update_option('fa_mne_version',FA_MNE_VERSION);
|
63 |
+
return;
|
64 |
+
}
|
65 |
+
|
66 |
+
if ( version_compare($current_version, '1.5.1') <=0)
|
67 |
+
{
|
68 |
+
/** update to 1.6.0
|
69 |
+
* setting the newly added options to checked as default
|
70 |
+
*/
|
71 |
+
$options['auto_plugin_update_send_email'] = '1';
|
72 |
+
$options['auto_theme_update_send_email'] = '1';
|
73 |
+
self::update_option('famne_options',$options);
|
74 |
+
}
|
75 |
+
|
76 |
+
if ($current_version == '1.1.0')
|
77 |
+
{
|
78 |
+
/** update 1.1.0 to 1.2.0
|
79 |
+
* setting the newly added options to checked as default
|
80 |
+
*/
|
81 |
+
|
82 |
+
$options['send_password_forgotten_email'] = '1';
|
83 |
+
$options['send_password_admin_forgotten_email'] ='1';
|
84 |
+
|
85 |
+
self::update_option('famne_options',$options);
|
86 |
+
}
|
87 |
+
|
88 |
+
|
89 |
+
/** update to 1.4.1
|
90 |
+
* setting the newly added options to checked as default
|
91 |
+
*/
|
92 |
+
|
93 |
+
if ( version_compare($current_version, '1.4.0') <=0)
|
94 |
+
{
|
95 |
+
$options['auto_core_update_send_email'] ='1';
|
96 |
+
self::update_option('famne_options',$options);
|
97 |
+
}
|
98 |
+
|
99 |
+
|
100 |
+
|
101 |
+
/** update 1.0 to 1.1 fix:
|
102 |
+
* update general wp_new_user_notification option into splitted options
|
103 |
+
*/
|
104 |
+
if ( version_compare($current_version, '1.0.0') <=0)
|
105 |
+
{
|
106 |
+
unset($options['wp_new_user_notification']);
|
107 |
+
$options['wp_new_user_notification_to_user'] ='1';
|
108 |
+
$options['wp_new_user_notification_to_admin'] ='1';
|
109 |
+
self::update_option('famne_options',$options);
|
110 |
+
}
|
111 |
+
|
112 |
+
/* UPDATE DONE! */
|
113 |
+
self::update_option('fa_mne_version',FA_MNE_VERSION);
|
114 |
+
}
|
115 |
+
}
|
116 |
+
}
|
117 |
+
endif;
|
includes/class.FAMNESettingsPage.php
ADDED
@@ -0,0 +1,322 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Manage notification emails settings page class
|
4 |
+
*
|
5 |
+
* Displays the settings page.
|
6 |
+
*
|
7 |
+
* This file is part of the Manage Notification Emails plugin
|
8 |
+
* You can find out more about this plugin at http://www.freeamigos.mx
|
9 |
+
* Copyright (c) 2006-2015 Virgial Berveling
|
10 |
+
*
|
11 |
+
* @package WordPress
|
12 |
+
* @author Virgial Berveling
|
13 |
+
* @copyright 2006-2015
|
14 |
+
*
|
15 |
+
* version: 1.3.0
|
16 |
+
*/
|
17 |
+
|
18 |
+
if (!class_exists('FAMNESettingsPage')):
|
19 |
+
|
20 |
+
class FAMNESettingsPage
|
21 |
+
{
|
22 |
+
/**
|
23 |
+
* Holds the values to be used in the fields callbacks
|
24 |
+
*/
|
25 |
+
private $options;
|
26 |
+
|
27 |
+
/**
|
28 |
+
* Start up
|
29 |
+
*/
|
30 |
+
public function __construct()
|
31 |
+
{
|
32 |
+
add_action( 'admin_menu', array( $this, 'add_plugin_page' ) );
|
33 |
+
add_action( 'admin_init', array( $this, 'page_init' ) );
|
34 |
+
add_filter( 'plugin_action_links_' . FA_MNE_PLUGIN_BASENAME, array($this,'add_action_links') );
|
35 |
+
add_action( 'init', array( $this, 'famne_load_textdomain') );
|
36 |
+
}
|
37 |
+
|
38 |
+
/**
|
39 |
+
* Add options page
|
40 |
+
*/
|
41 |
+
public function add_plugin_page()
|
42 |
+
{
|
43 |
+
// This page will be under "Settings"
|
44 |
+
add_options_page(
|
45 |
+
'Settings Admin',
|
46 |
+
'Notification e-mails',
|
47 |
+
'manage_options',
|
48 |
+
'famne-admin',
|
49 |
+
array( $this, 'create_admin_page' )
|
50 |
+
);
|
51 |
+
}
|
52 |
+
|
53 |
+
/**
|
54 |
+
* Options page callback
|
55 |
+
*/
|
56 |
+
public function create_admin_page()
|
57 |
+
{
|
58 |
+
// Set class property
|
59 |
+
$this->options = FAMNE::get_option( 'famne_options' );
|
60 |
+
|
61 |
+
?>
|
62 |
+
<div class="wrap">
|
63 |
+
<h2><?php _e('Manage the notification e-mails','manage-notification-emails')?></h2>
|
64 |
+
<form method="post" action="options.php">
|
65 |
+
<?php
|
66 |
+
// This prints out all hidden setting fields
|
67 |
+
settings_fields( 'famne_option_group' );
|
68 |
+
do_settings_sections( 'famne-admin' );
|
69 |
+
submit_button();
|
70 |
+
?>
|
71 |
+
</form>
|
72 |
+
|
73 |
+
<div style="padding:40px;text-align:center;color:rgba(0,0,0,0.7);">
|
74 |
+
<p class="description"><?php _e('If you find this plugin useful, you can show your appreciation here :-)','manage-notification-emails')?></p>
|
75 |
+
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
|
76 |
+
<input type="hidden" name="cmd" value="_s-xclick">
|
77 |
+
<input type="hidden" name="hosted_button_id" value="LTZWTLEDPULFE">
|
78 |
+
<input type="image" src="https://www.paypalobjects.com/nl_NL/NL/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal, de veilige en complete manier van online betalen.">
|
79 |
+
<img alt="" border="0" src="https://www.paypalobjects.com/nl_NL/i/scr/pixel.gif" width="1" height="1">
|
80 |
+
</form>
|
81 |
+
</div>
|
82 |
+
|
83 |
+
</div>
|
84 |
+
<?php
|
85 |
+
}
|
86 |
+
|
87 |
+
/**
|
88 |
+
* Register and add settings
|
89 |
+
*/
|
90 |
+
public function page_init()
|
91 |
+
{
|
92 |
+
register_setting(
|
93 |
+
'famne_option_group', // Option group
|
94 |
+
'famne_options', // Option name
|
95 |
+
array( $this, 'sanitize' ) // Sanitize
|
96 |
+
);
|
97 |
+
|
98 |
+
add_settings_section(
|
99 |
+
'setting_section_id', // ID
|
100 |
+
'', // Title
|
101 |
+
array( $this, 'print_section_info' ), // Callback
|
102 |
+
'famne-admin' // Page
|
103 |
+
);
|
104 |
+
|
105 |
+
add_settings_field(
|
106 |
+
'wp_new_user_notification_to_admin', // ID
|
107 |
+
__('New user notification to admin','manage-notification-emails'), // Title
|
108 |
+
array( $this, 'field1_callback' ), // Callback
|
109 |
+
'famne-admin', // Page
|
110 |
+
'setting_section_id' // Section
|
111 |
+
);
|
112 |
+
|
113 |
+
add_settings_field(
|
114 |
+
'wp_new_user_notification_to_user', // ID
|
115 |
+
__('New user notification to user','manage-notification-emails'), // Title
|
116 |
+
array( $this, 'field7_callback' ), // Callback
|
117 |
+
'famne-admin', // Page
|
118 |
+
'setting_section_id' // Section
|
119 |
+
);
|
120 |
+
|
121 |
+
add_settings_field(
|
122 |
+
'wp_notify_postauthor',
|
123 |
+
__('Notify post author','manage-notification-emails'),
|
124 |
+
array( $this, 'field2_callback' ),
|
125 |
+
'famne-admin',
|
126 |
+
'setting_section_id'
|
127 |
+
);
|
128 |
+
|
129 |
+
add_settings_field(
|
130 |
+
'wp_notify_moderator',
|
131 |
+
__('Notify moderator','manage-notification-emails'),
|
132 |
+
array( $this, 'field3_callback' ),
|
133 |
+
'famne-admin',
|
134 |
+
'setting_section_id'
|
135 |
+
);
|
136 |
+
|
137 |
+
add_settings_field(
|
138 |
+
'wp_password_change_notification',
|
139 |
+
__('Password change notification to admin','manage-notification-emails'),
|
140 |
+
array( $this, 'field4_callback' ),
|
141 |
+
'famne-admin',
|
142 |
+
'setting_section_id'
|
143 |
+
);
|
144 |
+
|
145 |
+
add_settings_field(
|
146 |
+
'send_password_change_email',
|
147 |
+
__('Password change notification to user','manage-notification-emails'),
|
148 |
+
array( $this, 'field5_callback' ),
|
149 |
+
'famne-admin',
|
150 |
+
'setting_section_id'
|
151 |
+
);
|
152 |
+
|
153 |
+
add_settings_field(
|
154 |
+
'send_email_change_email',
|
155 |
+
__('E-mail address change notification to user','manage-notification-emails'),
|
156 |
+
array( $this, 'field6_callback' ),
|
157 |
+
'famne-admin',
|
158 |
+
'setting_section_id'
|
159 |
+
);
|
160 |
+
|
161 |
+
add_settings_field(
|
162 |
+
'send_password_forgotten_email',
|
163 |
+
__('Password forgotten e-mail to user','manage-notification-emails'),
|
164 |
+
array( $this, 'field8_callback' ),
|
165 |
+
'famne-admin',
|
166 |
+
'setting_section_id'
|
167 |
+
);
|
168 |
+
|
169 |
+
add_settings_field(
|
170 |
+
'auto_core_update_send_email',
|
171 |
+
__('automatic Wordpress core update e-mail','manage-notification-emails'),
|
172 |
+
array( $this, 'field10_callback' ),
|
173 |
+
'famne-admin',
|
174 |
+
'setting_section_id'
|
175 |
+
);
|
176 |
+
|
177 |
+
add_settings_field(
|
178 |
+
'auto_plugin_update_send_email',
|
179 |
+
__('Automatic Wordpress plugin update e-mail','manage-notification-emails'),
|
180 |
+
array( $this, 'field11_callback' ),
|
181 |
+
'famne-admin',
|
182 |
+
'setting_section_id'
|
183 |
+
);
|
184 |
+
|
185 |
+
add_settings_field(
|
186 |
+
'auto_theme_update_send_email',
|
187 |
+
__('Automatic Wordpress theme update e-mail','manage-notification-emails'),
|
188 |
+
array( $this, 'field12_callback' ),
|
189 |
+
'famne-admin',
|
190 |
+
'setting_section_id'
|
191 |
+
);
|
192 |
+
|
193 |
+
add_settings_field(
|
194 |
+
'send_password_admin_forgotten_email',
|
195 |
+
__('Password forgotten e-mail to administrator','manage-notification-emails'),
|
196 |
+
array( $this, 'field9_callback' ),
|
197 |
+
'famne-admin',
|
198 |
+
'setting_section_id'
|
199 |
+
);
|
200 |
+
|
201 |
+
|
202 |
+
|
203 |
+
|
204 |
+
}
|
205 |
+
|
206 |
+
/**
|
207 |
+
* Sanitize each setting field as needed
|
208 |
+
*
|
209 |
+
* @param array $input Contains all settings fields as array keys
|
210 |
+
*/
|
211 |
+
public function sanitize( $input )
|
212 |
+
{
|
213 |
+
if (empty($input)) $input = array();
|
214 |
+
$new_input = array();
|
215 |
+
foreach( $input as $key=>$val )
|
216 |
+
$new_input[$key] = $val == '1'?'1':'';
|
217 |
+
|
218 |
+
return $new_input;
|
219 |
+
}
|
220 |
+
|
221 |
+
/**
|
222 |
+
* Print the Section text
|
223 |
+
*/
|
224 |
+
public function print_section_info()
|
225 |
+
{
|
226 |
+
_e('Manage your notification e-mail preferences below.','manage-notification-emails');
|
227 |
+
echo '<br/>';
|
228 |
+
_e('By unchecking the checkbox you prevent sending the specific e-mails.','manage-notification-emails');
|
229 |
+
}
|
230 |
+
|
231 |
+
/**
|
232 |
+
* Get the settings option array and print one of its values
|
233 |
+
*/
|
234 |
+
|
235 |
+
public function print_checkbox($name,$id,$message='')
|
236 |
+
{
|
237 |
+
$checked = isset( $this->options[$id]) && $this->options[$id] =='1' ?true:false;
|
238 |
+
|
239 |
+
if ($checked) {$add_check = 'checked="checked"';}else {$add_check='';};
|
240 |
+
print '<label><input type="checkbox" name="famne_options['.$id.']" value="1" '.$add_check.' /> '.__('Enable sending e-mail','manage-notification-emails').'</label>';
|
241 |
+
print '<p class="description">'.$message.'</p>';
|
242 |
+
}
|
243 |
+
|
244 |
+
|
245 |
+
public function field1_callback()
|
246 |
+
{
|
247 |
+
$this->print_checkbox('field1','wp_new_user_notification_to_admin',__('Sends an e-mail to the site admin after a new user is registered.','manage-notification-emails'));
|
248 |
+
}
|
249 |
+
|
250 |
+
public function field7_callback()
|
251 |
+
{
|
252 |
+
$this->print_checkbox('field7','wp_new_user_notification_to_user',__('Send e-mail with login credentials to a newly-registered user.','manage-notification-emails'));
|
253 |
+
}
|
254 |
+
|
255 |
+
public function field2_callback()
|
256 |
+
{
|
257 |
+
$this->print_checkbox('field2','wp_notify_postauthor',__('Send e-mail to an author (and/or others) of a comment/trackback/pingback on a post.','manage-notification-emails'));
|
258 |
+
}
|
259 |
+
|
260 |
+
public function field3_callback()
|
261 |
+
{
|
262 |
+
$this->print_checkbox('field3','wp_notify_moderator',__('Send e-mail to the moderator of the blog about a new comment that is awaiting approval.','manage-notification-emails'));
|
263 |
+
}
|
264 |
+
|
265 |
+
public function field4_callback()
|
266 |
+
{
|
267 |
+
$this->print_checkbox('field4','wp_password_change_notification',__('Send e-mail to the blog admin of a user changing his or her password.','manage-notification-emails'));
|
268 |
+
}
|
269 |
+
|
270 |
+
public function field5_callback()
|
271 |
+
{
|
272 |
+
$this->print_checkbox('field5','send_password_change_email',__('Send e-mail to registered user about changing his or her password. Be careful with this option, because when unchecked, the forgotten password request e-mails will be blocked too.','manage-notification-emails'));
|
273 |
+
}
|
274 |
+
|
275 |
+
public function field6_callback()
|
276 |
+
{
|
277 |
+
$this->print_checkbox('field6','send_email_change_email',__('Send e-mail to registered user about changing his or her E-mail address.','manage-notification-emails'));
|
278 |
+
}
|
279 |
+
|
280 |
+
public function field8_callback()
|
281 |
+
{
|
282 |
+
$this->print_checkbox('field8','send_password_forgotten_email',__('Send the forgotten password e-mail to registered user.<br/>(To prevent locking yourself out, sending of the forgotten password e-mail for administrators will still work)','manage-notification-emails'));
|
283 |
+
}
|
284 |
+
public function field9_callback()
|
285 |
+
{
|
286 |
+
$this->print_checkbox('field9','send_password_admin_forgotten_email',__('Send the forgotten password e-mail to administrators. Okay, this is a <strong style="color:#900">DANGEROUS OPTION !</strong><br/> So be warned, because unchecking this option prevents sending out the forgotten password e-mail to all administrators. So hold on to your own password and uncheck this one at your own risk ;-)','manage-notification-emails'));
|
287 |
+
}
|
288 |
+
|
289 |
+
public function field10_callback()
|
290 |
+
{
|
291 |
+
$this->print_checkbox('field10','auto_core_update_send_email',__('Sends an e-mail after a successful automatic Wordpress core update to administrators. E-mails about failed updates will always be sent to the administrators and cannot be disabled.','manage-notification-emails'));
|
292 |
+
}
|
293 |
+
|
294 |
+
public function field11_callback()
|
295 |
+
{
|
296 |
+
$this->print_checkbox('field11','auto_plugin_update_send_email',__('Sends an e-mail after a successful automatic plugin update to administrators. E-mails about failed plugin updates will always be sent to the administrators','manage-notification-emails'));
|
297 |
+
}
|
298 |
+
|
299 |
+
public function field12_callback()
|
300 |
+
{
|
301 |
+
$this->print_checkbox('field12','auto_theme_update_send_email',__('Sends an e-mail after a successful automatic theme update to administrators. E-mails about failed theme updates will always be sent to the administrators','manage-notification-emails'));
|
302 |
+
}
|
303 |
+
|
304 |
+
|
305 |
+
function add_action_links ( $links ) {
|
306 |
+
$mylinks = array(
|
307 |
+
'<a href="' . admin_url( 'options-general.php?page=famne-admin' ) . '">'.__('Settings').'</a>',
|
308 |
+
);
|
309 |
+
return array_merge( $links, $mylinks );
|
310 |
+
}
|
311 |
+
|
312 |
+
/**
|
313 |
+
* Translations.
|
314 |
+
*
|
315 |
+
* @since 1.4.2
|
316 |
+
*/
|
317 |
+
function famne_load_textdomain() {
|
318 |
+
load_plugin_textdomain( 'manage-notification-emails', false, basename(FA_MNE_PLUGIN_DIR) . '/languages' );
|
319 |
+
}
|
320 |
+
}
|
321 |
+
|
322 |
+
endif;
|
{modules/pluggable → includes}/pluggable-functions-1.2.php
RENAMED
File without changes
|
{modules/pluggable → includes}/pluggable-functions-1.3.php
RENAMED
File without changes
|
includes/pluggable-functions-1.4.php
ADDED
@@ -0,0 +1,329 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
|
4 |
+
STOP SENDING NOTIFICATION MAILS TO THE USERS
|
5 |
+
version: 1.5.1
|
6 |
+
updated: the core pluggable function wp_new_user_notification
|
7 |
+
added: passing through the $deprecated and $notify
|
8 |
+
fixed notice of $deprecated
|
9 |
+
*/
|
10 |
+
|
11 |
+
if (!defined('ABSPATH')) die();
|
12 |
+
|
13 |
+
$famne_options = get_option( 'famne_options' );
|
14 |
+
|
15 |
+
if (!function_exists('dont_send_password_change_email') ) :
|
16 |
+
/**
|
17 |
+
* Email password change notification to registered user.
|
18 |
+
*
|
19 |
+
*/
|
20 |
+
//echo "dont_send_password_change_email";
|
21 |
+
function dont_send_password_change_email( $send=false, $user='', $userdata='')
|
22 |
+
{
|
23 |
+
|
24 |
+
global $famne_options;
|
25 |
+
|
26 |
+
if (is_array($user)) $user = (object) $user;
|
27 |
+
|
28 |
+
if (!empty($famne_options['wp_password_change_notification']) ) :
|
29 |
+
|
30 |
+
// send a copy of password change notification to the admin
|
31 |
+
// but check to see if it's the admin whose password we're changing, and skip this
|
32 |
+
if ( 0 !== strcasecmp( $user->user_email, get_option( 'admin_email' ) ) ) {
|
33 |
+
$message = sprintf(__('Password Lost and Changed for user: %s'), $user->user_login) . "\r\n";
|
34 |
+
// The blogname option is escaped with esc_html on the way into the database in sanitize_option
|
35 |
+
// we want to reverse this for the plain text arena of emails.
|
36 |
+
$blogname = wp_specialchars_decode(get_option('blogname'), ENT_QUOTES);
|
37 |
+
wp_mail(get_option('admin_email'), sprintf(__('[%s] Password Lost/Changed'), $blogname), $message);
|
38 |
+
}
|
39 |
+
|
40 |
+
endif;
|
41 |
+
|
42 |
+
if (empty($famne_options['send_password_change_email']) ) :
|
43 |
+
return false;
|
44 |
+
else :
|
45 |
+
return true;
|
46 |
+
endif;
|
47 |
+
}
|
48 |
+
add_filter('send_password_change_email', 'dont_send_password_change_email',1,3);
|
49 |
+
endif;
|
50 |
+
|
51 |
+
|
52 |
+
if (empty($famne_options['send_email_change_email']) && !function_exists('dont_send_email_change_email') ) :
|
53 |
+
/**
|
54 |
+
* Email users e-mail change notification to registered user.
|
55 |
+
*
|
56 |
+
*/
|
57 |
+
//echo "dont_send_email_change_email off";
|
58 |
+
function dont_send_email_change_email( $send=false, $user='', $userdata='')
|
59 |
+
{
|
60 |
+
return false;
|
61 |
+
}
|
62 |
+
add_filter('send_email_change_email', 'dont_send_email_change_email',1,3);
|
63 |
+
endif;
|
64 |
+
|
65 |
+
|
66 |
+
|
67 |
+
if (!function_exists('wp_new_user_notification') ) :
|
68 |
+
/**
|
69 |
+
* Email login credentials to a newly-registered user.
|
70 |
+
*
|
71 |
+
* A new user registration notification is also sent to admin email.
|
72 |
+
*/
|
73 |
+
//echo "wp_new_user_notification off";
|
74 |
+
function wp_new_user_notification( $user_id, $deprecated = null, $notify = '' ) {
|
75 |
+
|
76 |
+
global $famne_options;
|
77 |
+
|
78 |
+
if (!empty($famne_options['wp_new_user_notification_to_admin']))
|
79 |
+
{
|
80 |
+
fa_new_user_notification_to_admin($user_id,$deprecated,$notify);
|
81 |
+
}
|
82 |
+
|
83 |
+
if (!empty($famne_options['wp_new_user_notification_to_user']))
|
84 |
+
{
|
85 |
+
fa_new_user_notification_to_user($user_id,$deprecated,$notify);
|
86 |
+
}
|
87 |
+
}
|
88 |
+
endif;
|
89 |
+
|
90 |
+
if (empty($famne_options['wp_notify_postauthor']) && !function_exists('wp_notify_postauthor') ) :
|
91 |
+
/**
|
92 |
+
* Notify an author (and/or others) of a comment/trackback/pingback on a post.
|
93 |
+
*/
|
94 |
+
//echo "wp_notify_postauthor off";
|
95 |
+
function wp_notify_postauthor( $comment_id, $deprecated = null ) {}
|
96 |
+
endif;
|
97 |
+
|
98 |
+
if (empty($famne_options['wp_notify_moderator']) && !function_exists('wp_notify_moderator') ) :
|
99 |
+
/**
|
100 |
+
* Notifies the moderator of the blog about a new comment that is awaiting approval.
|
101 |
+
*/
|
102 |
+
//echo "wp_notify_moderator off";
|
103 |
+
function wp_notify_moderator($comment_id) {}
|
104 |
+
endif;
|
105 |
+
|
106 |
+
|
107 |
+
|
108 |
+
|
109 |
+
if (empty($famne_options['wp_password_change_notification']) && !function_exists('wp_password_change_notification') ) :
|
110 |
+
/**
|
111 |
+
* Notify the blog admin of a user changing password, normally via email.
|
112 |
+
*/
|
113 |
+
function wp_password_change_notification($user) {}
|
114 |
+
|
115 |
+
|
116 |
+
endif;
|
117 |
+
|
118 |
+
|
119 |
+
|
120 |
+
if ((empty($famne_options['send_password_forgotten_email']) || empty($famne_options['send_password_admin_forgotten_email'])) && !function_exists('dont_send_password_forgotten_email') ) :
|
121 |
+
/**
|
122 |
+
* Email forgotten password notification to registered user.
|
123 |
+
*
|
124 |
+
*/
|
125 |
+
//echo "dont_send_password_forgotten_email off";exit;
|
126 |
+
function dont_send_password_forgotten_email( $send=true, $user_id=0 )
|
127 |
+
{
|
128 |
+
global $famne_options;
|
129 |
+
|
130 |
+
$is_administrator = fa_user_is_administrator($user_id);
|
131 |
+
|
132 |
+
if ($is_administrator && empty($famne_options['send_password_admin_forgotten_email']))
|
133 |
+
{
|
134 |
+
// stop sending admin forgot email
|
135 |
+
return false;
|
136 |
+
}
|
137 |
+
if (!$is_administrator && empty($famne_options['send_password_forgotten_email']))
|
138 |
+
{
|
139 |
+
// stop sending user forgot email
|
140 |
+
return false;
|
141 |
+
}
|
142 |
+
// none of the above so give the default status back
|
143 |
+
return $send;
|
144 |
+
}
|
145 |
+
add_filter('allow_password_reset', 'dont_send_password_forgotten_email',1,3);
|
146 |
+
endif;
|
147 |
+
|
148 |
+
|
149 |
+
|
150 |
+
|
151 |
+
if (empty($famne_options['auto_core_update_send_email']) && !function_exists('fa_dont_sent_auto_core_update_emails') ) :
|
152 |
+
/**
|
153 |
+
* Send email when wordpress automatic updated.
|
154 |
+
*
|
155 |
+
*/
|
156 |
+
//echo "auto_core_update_send_email off";exit;
|
157 |
+
|
158 |
+
|
159 |
+
function fa_dont_sent_auto_core_update_emails( $send, $type, $core_update, $result ) {
|
160 |
+
if ( ! empty( $type ) && $type == 'success' ) {
|
161 |
+
return false;
|
162 |
+
}
|
163 |
+
return true;
|
164 |
+
}
|
165 |
+
add_filter( 'auto_core_update_send_email', 'fa_dont_sent_auto_core_update_emails', 10, 4 );
|
166 |
+
endif;
|
167 |
+
|
168 |
+
|
169 |
+
|
170 |
+
function fa_new_user_notification_to_admin ($user_id,$deprecated,$notify='')
|
171 |
+
{
|
172 |
+
|
173 |
+
//Most parts of this function are copied form pluggable.php
|
174 |
+
|
175 |
+
if ( $deprecated !== null ) {
|
176 |
+
_deprecated_argument( __FUNCTION__, '4.3.1' );
|
177 |
+
}
|
178 |
+
|
179 |
+
global $wpdb, $wp_hasher;
|
180 |
+
$user = get_userdata( $user_id );
|
181 |
+
|
182 |
+
// The blogname option is escaped with esc_html on the way into the database in sanitize_option
|
183 |
+
// we want to reverse this for the plain text arena of emails.
|
184 |
+
$blogname = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES );
|
185 |
+
|
186 |
+
if ( 'user' !== $notify ) {
|
187 |
+
$switched_locale = switch_to_locale( get_locale() );
|
188 |
+
|
189 |
+
/* translators: %s: site title */
|
190 |
+
$message = sprintf( __( 'New user registration on your site %s:' ), $blogname ) . "\r\n\r\n";
|
191 |
+
/* translators: %s: user login */
|
192 |
+
$message .= sprintf( __( 'Username: %s' ), $user->user_login ) . "\r\n\r\n";
|
193 |
+
/* translators: %s: user email address */
|
194 |
+
$message .= sprintf( __( 'Email: %s' ), $user->user_email ) . "\r\n";
|
195 |
+
|
196 |
+
$wp_new_user_notification_email_admin = array(
|
197 |
+
'to' => get_option( 'admin_email' ),
|
198 |
+
/* translators: New user registration notification email subject. %s: Site title */
|
199 |
+
'subject' => __( '[%s] New User Registration' ),
|
200 |
+
'message' => $message,
|
201 |
+
'headers' => '',
|
202 |
+
);
|
203 |
+
|
204 |
+
/**
|
205 |
+
* Filters the contents of the new user notification email sent to the site admin.
|
206 |
+
*
|
207 |
+
* @since 4.9.0
|
208 |
+
*
|
209 |
+
* @param array $wp_new_user_notification_email {
|
210 |
+
* Used to build wp_mail().
|
211 |
+
*
|
212 |
+
* @type string $to The intended recipient - site admin email address.
|
213 |
+
* @type string $subject The subject of the email.
|
214 |
+
* @type string $message The body of the email.
|
215 |
+
* @type string $headers The headers of the email.
|
216 |
+
* }
|
217 |
+
* @param WP_User $user User object for new user.
|
218 |
+
* @param string $blogname The site title.
|
219 |
+
*/
|
220 |
+
$wp_new_user_notification_email_admin = apply_filters( 'wp_new_user_notification_email_admin', $wp_new_user_notification_email_admin, $user, $blogname );
|
221 |
+
|
222 |
+
@wp_mail(
|
223 |
+
$wp_new_user_notification_email_admin['to'],
|
224 |
+
wp_specialchars_decode( sprintf( $wp_new_user_notification_email_admin['subject'], $blogname ) ),
|
225 |
+
$wp_new_user_notification_email_admin['message'],
|
226 |
+
$wp_new_user_notification_email_admin['headers']
|
227 |
+
);
|
228 |
+
|
229 |
+
if ( $switched_locale ) {
|
230 |
+
restore_previous_locale();
|
231 |
+
}
|
232 |
+
}
|
233 |
+
}
|
234 |
+
|
235 |
+
|
236 |
+
function fa_new_user_notification_to_user($user_id,$deprecated=null,$notify='')
|
237 |
+
{
|
238 |
+
if ( $deprecated !== null ) {
|
239 |
+
_deprecated_argument( __FUNCTION__, '4.3.1' );
|
240 |
+
}
|
241 |
+
|
242 |
+
// Accepts only 'user', 'admin' , 'both' or default '' as $notify
|
243 |
+
if ( ! in_array( $notify, array( 'user', 'admin', 'both', '' ), true ) ) {
|
244 |
+
return;
|
245 |
+
}
|
246 |
+
|
247 |
+
global $wpdb, $wp_hasher;
|
248 |
+
$user = get_userdata( $user_id );
|
249 |
+
|
250 |
+
// The blogname option is escaped with esc_html on the way into the database in sanitize_option
|
251 |
+
// we want to reverse this for the plain text arena of emails.
|
252 |
+
$blogname = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES );
|
253 |
+
|
254 |
+
// `$deprecated was pre-4.3 `$plaintext_pass`. An empty `$plaintext_pass` didn't sent a user notification.
|
255 |
+
if ( 'admin' === $notify || ( empty( $deprecated ) && empty( $notify ) ) ) {
|
256 |
+
return;
|
257 |
+
}
|
258 |
+
|
259 |
+
// Generate something random for a password reset key.
|
260 |
+
$key = wp_generate_password( 20, false );
|
261 |
+
|
262 |
+
/** This action is documented in wp-login.php */
|
263 |
+
do_action( 'retrieve_password_key', $user->user_login, $key );
|
264 |
+
|
265 |
+
// Now insert the key, hashed, into the DB.
|
266 |
+
if ( empty( $wp_hasher ) ) {
|
267 |
+
require_once ABSPATH . WPINC . '/class-phpass.php';
|
268 |
+
$wp_hasher = new PasswordHash( 8, true );
|
269 |
+
}
|
270 |
+
$hashed = time() . ':' . $wp_hasher->HashPassword( $key );
|
271 |
+
$wpdb->update( $wpdb->users, array( 'user_activation_key' => $hashed ), array( 'user_login' => $user->user_login ) );
|
272 |
+
|
273 |
+
$switched_locale = switch_to_locale( get_user_locale( $user ) );
|
274 |
+
|
275 |
+
/* translators: %s: user login */
|
276 |
+
$message = sprintf( __( 'Username: %s' ), $user->user_login ) . "\r\n\r\n";
|
277 |
+
$message .= __( 'To set your password, visit the following address:' ) . "\r\n\r\n";
|
278 |
+
$message .= '<' . network_site_url( "wp-login.php?action=rp&key=$key&login=" . rawurlencode( $user->user_login ), 'login' ) . ">\r\n\r\n";
|
279 |
+
|
280 |
+
$message .= wp_login_url() . "\r\n";
|
281 |
+
|
282 |
+
$wp_new_user_notification_email = array(
|
283 |
+
'to' => $user->user_email,
|
284 |
+
/* translators: Login details notification email subject. %s: Site title */
|
285 |
+
'subject' => __( '[%s] Login Details' ),
|
286 |
+
'message' => $message,
|
287 |
+
'headers' => '',
|
288 |
+
);
|
289 |
+
|
290 |
+
/**
|
291 |
+
* Filters the contents of the new user notification email sent to the new user.
|
292 |
+
*
|
293 |
+
* @since 4.9.0
|
294 |
+
*
|
295 |
+
* @param array $wp_new_user_notification_email {
|
296 |
+
* Used to build wp_mail().
|
297 |
+
*
|
298 |
+
* @type string $to The intended recipient - New user email address.
|
299 |
+
* @type string $subject The subject of the email.
|
300 |
+
* @type string $message The body of the email.
|
301 |
+
* @type string $headers The headers of the email.
|
302 |
+
* }
|
303 |
+
* @param WP_User $user User object for new user.
|
304 |
+
* @param string $blogname The site title.
|
305 |
+
*/
|
306 |
+
$wp_new_user_notification_email = apply_filters( 'wp_new_user_notification_email', $wp_new_user_notification_email, $user, $blogname );
|
307 |
+
|
308 |
+
wp_mail(
|
309 |
+
$wp_new_user_notification_email['to'],
|
310 |
+
wp_specialchars_decode( sprintf( $wp_new_user_notification_email['subject'], $blogname ) ),
|
311 |
+
$wp_new_user_notification_email['message'],
|
312 |
+
$wp_new_user_notification_email['headers']
|
313 |
+
);
|
314 |
+
|
315 |
+
if ( $switched_locale ) {
|
316 |
+
restore_previous_locale();
|
317 |
+
}
|
318 |
+
}
|
319 |
+
|
320 |
+
function fa_user_is_administrator($user_id=0)
|
321 |
+
{
|
322 |
+
$user = new WP_User( intval($user_id) );
|
323 |
+
$is_administrator = false;
|
324 |
+
if ( !empty( $user->roles ) && is_array( $user->roles ) ) {
|
325 |
+
foreach ( $user->roles as $role )
|
326 |
+
if ( strtolower($role) == 'administrator') $is_administrator = true;
|
327 |
+
}
|
328 |
+
return $is_administrator;
|
329 |
+
}
|
{modules/pluggable → includes}/pluggable-functions-1.5.php
RENAMED
@@ -2,6 +2,8 @@
|
|
2 |
/**
|
3 |
|
4 |
STOP SENDING NOTIFICATION MAILS TO THE USERS
|
|
|
|
|
5 |
version 1.5.2
|
6 |
added: Email automatic plugin update notification to admin option
|
7 |
added: Email automatic theme update notification to admin option
|
@@ -15,12 +17,6 @@ if (!defined('ABSPATH')) die();
|
|
15 |
|
16 |
$famne_options = FAMNE::get_option( 'famne_options' );
|
17 |
|
18 |
-
FAMNE::AddModule('pluggable',array(
|
19 |
-
'name' => 'Pluggable',
|
20 |
-
'version'=>'1.5.1'
|
21 |
-
));
|
22 |
-
|
23 |
-
|
24 |
if (!function_exists('dont_send_password_change_email') ) :
|
25 |
/**
|
26 |
* Email password change notification to registered user.
|
@@ -346,11 +342,10 @@ if (empty($famne_options['auto_plugin_update_send_email']) ) :
|
|
346 |
//echo "auto_plugin_update_send_email off";
|
347 |
function fa_auto_plugin_update_send_email($notifications_enabled,$update_results_plugins)
|
348 |
{
|
349 |
-
|
350 |
-
|
351 |
-
|
352 |
-
|
353 |
-
}
|
354 |
}
|
355 |
return $notifications_enabled;
|
356 |
}
|
2 |
/**
|
3 |
|
4 |
STOP SENDING NOTIFICATION MAILS TO THE USERS
|
5 |
+
version 1.5.3
|
6 |
+
fixed: Email automatic plugin update notification to admin option
|
7 |
version 1.5.2
|
8 |
added: Email automatic plugin update notification to admin option
|
9 |
added: Email automatic theme update notification to admin option
|
17 |
|
18 |
$famne_options = FAMNE::get_option( 'famne_options' );
|
19 |
|
|
|
|
|
|
|
|
|
|
|
|
|
20 |
if (!function_exists('dont_send_password_change_email') ) :
|
21 |
/**
|
22 |
* Email password change notification to registered user.
|
342 |
//echo "auto_plugin_update_send_email off";
|
343 |
function fa_auto_plugin_update_send_email($notifications_enabled,$update_results_plugins)
|
344 |
{
|
345 |
+
$notifications_enabled = false;
|
346 |
+
foreach ( $update_results_plugins as $update_result ) {
|
347 |
+
// do we have a failed update?
|
348 |
+
if ( true !== $update_result->result ) $notifications_enabled = true;
|
|
|
349 |
}
|
350 |
return $notifications_enabled;
|
351 |
}
|
includes/pluggable-functions.php
ADDED
@@ -0,0 +1,213 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
|
4 |
+
STOP SENDING NOTIFICATION MAILS TO THE USERS
|
5 |
+
version: 1.2.0
|
6 |
+
*/
|
7 |
+
|
8 |
+
if (!defined('ABSPATH')) die();
|
9 |
+
|
10 |
+
$famne_options = get_option( 'famne_options' );
|
11 |
+
|
12 |
+
if (!function_exists('dont_send_password_change_email') ) :
|
13 |
+
/**
|
14 |
+
* Email password change notification to registered user.
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
//echo "dont_send_password_change_email";
|
18 |
+
function dont_send_password_change_email( $send=false, $user='', $userdata='')
|
19 |
+
{
|
20 |
+
|
21 |
+
global $famne_options;
|
22 |
+
|
23 |
+
if (is_array($user)) $user = (object) $user;
|
24 |
+
|
25 |
+
if (!empty($famne_options['wp_password_change_notification']) ) :
|
26 |
+
|
27 |
+
// send a copy of password change notification to the admin
|
28 |
+
// but check to see if it's the admin whose password we're changing, and skip this
|
29 |
+
if ( 0 !== strcasecmp( $user->user_email, get_option( 'admin_email' ) ) ) {
|
30 |
+
$message = sprintf(__('Password Lost and Changed for user: %s'), $user->user_login) . "\r\n";
|
31 |
+
// The blogname option is escaped with esc_html on the way into the database in sanitize_option
|
32 |
+
// we want to reverse this for the plain text arena of emails.
|
33 |
+
$blogname = wp_specialchars_decode(get_option('blogname'), ENT_QUOTES);
|
34 |
+
wp_mail(get_option('admin_email'), sprintf(__('[%s] Password Lost/Changed'), $blogname), $message);
|
35 |
+
}
|
36 |
+
|
37 |
+
endif;
|
38 |
+
|
39 |
+
if (empty($famne_options['send_password_change_email']) ) :
|
40 |
+
return false;
|
41 |
+
else :
|
42 |
+
return true;
|
43 |
+
endif;
|
44 |
+
}
|
45 |
+
add_filter('send_password_change_email', 'dont_send_password_change_email',1,3);
|
46 |
+
endif;
|
47 |
+
|
48 |
+
|
49 |
+
if (empty($famne_options['send_email_change_email']) && !function_exists('dont_send_email_change_email') ) :
|
50 |
+
/**
|
51 |
+
* Email users e-mail change notification to registered user.
|
52 |
+
*
|
53 |
+
*/
|
54 |
+
//echo "dont_send_email_change_email off";
|
55 |
+
function dont_send_email_change_email( $send=false, $user='', $userdata='')
|
56 |
+
{
|
57 |
+
return false;
|
58 |
+
}
|
59 |
+
add_filter('send_email_change_email', 'dont_send_email_change_email',1,3);
|
60 |
+
endif;
|
61 |
+
|
62 |
+
|
63 |
+
|
64 |
+
if (!function_exists('wp_new_user_notification') ) :
|
65 |
+
/**
|
66 |
+
* Email login credentials to a newly-registered user.
|
67 |
+
*
|
68 |
+
* A new user registration notification is also sent to admin email.
|
69 |
+
*/
|
70 |
+
//echo "wp_new_user_notification off";
|
71 |
+
function wp_new_user_notification( $user_id, $notify = '' ) {
|
72 |
+
|
73 |
+
global $famne_options;
|
74 |
+
|
75 |
+
if (!empty($famne_options['wp_new_user_notification_to_admin']))
|
76 |
+
{
|
77 |
+
fa_new_user_notification_to_admin($user_id);
|
78 |
+
}
|
79 |
+
|
80 |
+
if (!empty($famne_options['wp_new_user_notification_to_user']))
|
81 |
+
{
|
82 |
+
fa_new_user_notification_to_user($user_id);
|
83 |
+
}
|
84 |
+
}
|
85 |
+
endif;
|
86 |
+
|
87 |
+
if (empty($famne_options['wp_notify_postauthor']) && !function_exists('wp_notify_postauthor') ) :
|
88 |
+
/**
|
89 |
+
* Notify an author (and/or others) of a comment/trackback/pingback on a post.
|
90 |
+
*/
|
91 |
+
//echo "wp_notify_postauthor off";
|
92 |
+
function wp_notify_postauthor( $comment_id, $deprecated = null ) {}
|
93 |
+
endif;
|
94 |
+
|
95 |
+
if (empty($famne_options['wp_notify_moderator']) && !function_exists('wp_notify_moderator') ) :
|
96 |
+
/**
|
97 |
+
* Notifies the moderator of the blog about a new comment that is awaiting approval.
|
98 |
+
*/
|
99 |
+
//echo "wp_notify_moderator off";
|
100 |
+
function wp_notify_moderator($comment_id) {}
|
101 |
+
endif;
|
102 |
+
|
103 |
+
|
104 |
+
|
105 |
+
|
106 |
+
if (empty($famne_options['wp_password_change_notification']) && !function_exists('wp_password_change_notification') ) :
|
107 |
+
/**
|
108 |
+
* Notify the blog admin of a user changing password, normally via email.
|
109 |
+
*/
|
110 |
+
function wp_password_change_notification($user) {}
|
111 |
+
|
112 |
+
|
113 |
+
endif;
|
114 |
+
|
115 |
+
|
116 |
+
|
117 |
+
if ((empty($famne_options['send_password_forgotten_email']) || empty($famne_options['send_password_admin_forgotten_email'])) && !function_exists('dont_send_password_forgotten_email') ) :
|
118 |
+
/**
|
119 |
+
* Email forgotten password notification to registered user.
|
120 |
+
*
|
121 |
+
*/
|
122 |
+
//echo "dont_send_password_forgotten_email off";exit;
|
123 |
+
function dont_send_password_forgotten_email( $send=true, $user_id=0 )
|
124 |
+
{
|
125 |
+
global $famne_options;
|
126 |
+
|
127 |
+
$is_administrator = fa_user_is_administrator($user_id);
|
128 |
+
|
129 |
+
if ($is_administrator && empty($famne_options['send_password_admin_forgotten_email']))
|
130 |
+
{
|
131 |
+
// stop sending admin forgot email
|
132 |
+
return false;
|
133 |
+
}
|
134 |
+
if (!$is_administrator && empty($famne_options['send_password_forgotten_email']))
|
135 |
+
{
|
136 |
+
// stop sending user forgot email
|
137 |
+
return false;
|
138 |
+
}
|
139 |
+
// none of the above so give the default status back
|
140 |
+
return $send;
|
141 |
+
}
|
142 |
+
add_filter('allow_password_reset', 'dont_send_password_forgotten_email',1,3);
|
143 |
+
endif;
|
144 |
+
|
145 |
+
|
146 |
+
|
147 |
+
|
148 |
+
|
149 |
+
|
150 |
+
function fa_new_user_notification_to_admin ($user_id)
|
151 |
+
{
|
152 |
+
|
153 |
+
//Most parts of this function are copied form pluggable.php
|
154 |
+
|
155 |
+
global $wpdb;
|
156 |
+
$user = get_userdata( $user_id );
|
157 |
+
|
158 |
+
// The blogname option is escaped with esc_html on the way into the database in sanitize_option
|
159 |
+
// we want to reverse this for the plain text arena of emails.
|
160 |
+
$blogname = wp_specialchars_decode(get_option('blogname'), ENT_QUOTES);
|
161 |
+
|
162 |
+
$message = sprintf(__('New user registration on your site %s:'), $blogname) . "\r\n\r\n";
|
163 |
+
$message .= sprintf(__('Username: %s'), $user->user_login) . "\r\n\r\n";
|
164 |
+
$message .= sprintf(__('E-mail: %s'), $user->user_email) . "\r\n";
|
165 |
+
|
166 |
+
|
167 |
+
@wp_mail(get_option('admin_email'), sprintf(__('[%s] New User Registration'), $blogname), $message);
|
168 |
+
}
|
169 |
+
|
170 |
+
|
171 |
+
function fa_new_user_notification_to_user($user_id)
|
172 |
+
{
|
173 |
+
global $wpdb;
|
174 |
+
$user = get_userdata( $user_id );
|
175 |
+
|
176 |
+
// The blogname option is escaped with esc_html on the way into the database in sanitize_option
|
177 |
+
// we want to reverse this for the plain text arena of emails.
|
178 |
+
$blogname = wp_specialchars_decode(get_option('blogname'), ENT_QUOTES);
|
179 |
+
|
180 |
+
|
181 |
+
// Generate something random for a password reset key.
|
182 |
+
$key = wp_generate_password( 20, false );
|
183 |
+
|
184 |
+
/** This action is documented in wp-login.php */
|
185 |
+
do_action( 'retrieve_password_key', $user->user_login, $key );
|
186 |
+
|
187 |
+
// Now insert the key, hashed, into the DB.
|
188 |
+
if ( empty( $wp_hasher ) ) {
|
189 |
+
require_once ABSPATH . WPINC . '/class-phpass.php';
|
190 |
+
$wp_hasher = new PasswordHash( 8, true );
|
191 |
+
}
|
192 |
+
$hashed = time() . ':' . $wp_hasher->HashPassword( $key );
|
193 |
+
$wpdb->update( $wpdb->users, array( 'user_activation_key' => $hashed ), array( 'user_login' => $user->user_login ) );
|
194 |
+
|
195 |
+
$message = sprintf(__('Username: %s'), $user->user_login) . "\r\n\r\n";
|
196 |
+
$message .= __('To set your password, visit the following address:') . "\r\n\r\n";
|
197 |
+
$message .= '<' . network_site_url("wp-login.php?action=rp&key=$key&login=" . rawurlencode($user->user_login), 'login') . ">\r\n\r\n";
|
198 |
+
|
199 |
+
$message .= wp_login_url() . "\r\n";
|
200 |
+
|
201 |
+
wp_mail($user->user_email, sprintf(__('[%s] Your username and password info'), $blogname), $message);
|
202 |
+
}
|
203 |
+
|
204 |
+
function fa_user_is_administrator($user_id=0)
|
205 |
+
{
|
206 |
+
$user = new WP_User( intval($user_id) );
|
207 |
+
$is_administrator = false;
|
208 |
+
if ( !empty( $user->roles ) && is_array( $user->roles ) ) {
|
209 |
+
foreach ( $user->roles as $role )
|
210 |
+
if ( strtolower($role) == 'administrator') $is_administrator = true;
|
211 |
+
}
|
212 |
+
return $is_administrator;
|
213 |
+
}
|
languages/manage-notification-emails-nl_NL.mo
CHANGED
Binary file
|
languages/manage-notification-emails-nl_NL.po
CHANGED
@@ -3,8 +3,8 @@ msgstr ""
|
|
3 |
"Project-Id-Version: Famne\n"
|
4 |
"Report-Msgid-Bugs-To: \n"
|
5 |
"POT-Creation-Date: \n"
|
6 |
-
"PO-Revision-Date:
|
7 |
-
"Language-Team:
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=UTF-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
@@ -14,161 +14,104 @@ msgstr ""
|
|
14 |
"_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n"
|
15 |
"X-Poedit-Basepath: ..\n"
|
16 |
"X-Textdomain-Support: yes\n"
|
17 |
-
"X-Generator:
|
18 |
"Last-Translator: \n"
|
19 |
-
"Language:
|
20 |
"X-Poedit-SearchPath-0: .\n"
|
21 |
|
22 |
-
#:
|
23 |
-
msgid "Automatic Wordpress core update e-mail"
|
24 |
-
msgstr "Automatische Wordpress core update e-mail"
|
25 |
-
|
26 |
-
#: modules/settings-page/views/settings.php:27
|
27 |
-
msgid "Automatic Wordpress plugin update e-mail"
|
28 |
-
msgstr "Automatische Wordpress plugin update e-mail"
|
29 |
-
|
30 |
-
#: modules/settings-page/views/settings.php:28
|
31 |
-
msgid "Automatic Wordpress theme update e-mail"
|
32 |
-
msgstr "Automatische Wordpress thema update e-mail"
|
33 |
-
|
34 |
-
#: modules/settings-page/views/extra.php:10
|
35 |
-
msgid "Available Manage Notification E-mail Modules"
|
36 |
-
msgstr "Beschikbare Manage Notification E-mail Modules"
|
37 |
-
|
38 |
-
#: modules/settings-page/class.FAMNESettingsPage.php:58
|
39 |
-
msgid "Core options"
|
40 |
-
msgstr "Core opties"
|
41 |
-
|
42 |
-
#: modules/settings-page/views/settings.php:14
|
43 |
-
msgid "E-mail address change notification to user"
|
44 |
-
msgstr "E-mailadres wijziging notificatie aan gebruiker"
|
45 |
-
|
46 |
-
#: modules/user-email-changed.php:37
|
47 |
-
msgid "E-mail address changed by user"
|
48 |
-
msgstr "E-mailadres is gewijzigd door gebruiker"
|
49 |
-
|
50 |
-
#: modules/custom-recipients.php:37
|
51 |
-
msgid "E-mail address(es)"
|
52 |
-
msgstr "E-mailadres(sen)"
|
53 |
-
|
54 |
-
#: modules/custom-recipients.php:35
|
55 |
-
msgid "Extra admin recipients"
|
56 |
-
msgstr "Extra admin adressen"
|
57 |
-
|
58 |
-
#: modules/settings-page/views/modules.php:8
|
59 |
-
msgid "Extra modules"
|
60 |
-
msgstr "Extra modules"
|
61 |
-
|
62 |
-
#. Author URI of the plugin
|
63 |
-
msgid "https://www.freeamigos.nl"
|
64 |
-
msgstr "https://www.freeamigos.nl"
|
65 |
-
|
66 |
-
#. URI of the plugin
|
67 |
-
msgid "https://www.freeamigos.nl/wp-plugins/manage-notification-emails/1.7.0"
|
68 |
-
msgstr "https://www.freeamigos.nl/wp-plugins/manage-notification-emails/1.7.0"
|
69 |
-
|
70 |
-
#: modules/settings-page/views/container.php:27
|
71 |
-
msgid "If you find this plugin useful, you can show your appreciation here :-)"
|
72 |
-
msgstr "Geef een kleine donatie als je deze plugin handig vindt"
|
73 |
-
|
74 |
-
#: modules/settings-page/class.FAMNESettingsPage.php:60
|
75 |
-
#: modules/settings-page/views/extra.php:8
|
76 |
-
msgid "Information"
|
77 |
-
msgstr "Informatie"
|
78 |
-
|
79 |
-
#. Name of the plugin
|
80 |
-
msgid "Manage Notification E-mails"
|
81 |
-
msgstr "Beheer Notification E-mails"
|
82 |
-
|
83 |
-
#: modules/settings-page/views/container.php:7
|
84 |
msgid "Manage the notification e-mails"
|
85 |
msgstr "Beheer notificatie e-mails"
|
86 |
|
87 |
-
#:
|
88 |
-
msgid "
|
89 |
-
msgstr "
|
90 |
-
|
91 |
-
#: modules/settings-page/class.FAMNESettingsPage.php:59
|
92 |
-
msgid "Modules"
|
93 |
-
msgstr "Modules"
|
94 |
|
95 |
-
#:
|
96 |
msgid "New user notification to admin"
|
97 |
msgstr "Nieuwe gebruiker notificatie aan sitebeheerder"
|
98 |
|
99 |
-
#:
|
100 |
msgid "New user notification to user"
|
101 |
msgstr "Nieuwe gebruiker notificatie aan gebruiker"
|
102 |
|
103 |
-
#:
|
104 |
-
msgid "Notify moderator"
|
105 |
-
msgstr "Notificeer moderator"
|
106 |
-
|
107 |
-
#: modules/settings-page/views/settings.php:11
|
108 |
msgid "Notify post author"
|
109 |
msgstr "Notificeer bericht schrijver"
|
110 |
|
111 |
-
#:
|
112 |
-
msgid ""
|
113 |
-
|
114 |
-
" So be warned, because unchecking this option prevents sending out the "
|
115 |
-
"forgotten password e-mail to all administrators. So hold on to your own "
|
116 |
-
"password and uncheck this one at your own risk ;-)"
|
117 |
-
msgstr ""
|
118 |
-
"Okay, dit is een <strong style=\"color:#900\">GEVAARLIJKE OPTIE !</strong>"
|
119 |
-
"<br/> Wees gewaarschuwd, omdat het uitzetten van deze optie het verzenden "
|
120 |
-
"van de vergeten wachtwoord e-mail aan adminstratoren blokeerd. Dus zorg dat "
|
121 |
-
"je jouw wachtwoord goed bewaard en zet deze optie uit op eigen "
|
122 |
-
"verantwoording ;-)"
|
123 |
-
|
124 |
-
#: modules/settings-page/views/settings.php:19
|
125 |
-
msgid "Options for e-mails to administrators"
|
126 |
-
msgstr "Opties voor e-mails aan administrators"
|
127 |
-
|
128 |
-
#: modules/settings-page/views/settings.php:7
|
129 |
-
msgid "Options for e-mails to users"
|
130 |
-
msgstr "Opties voor e-mails aan administratoren"
|
131 |
|
132 |
-
#:
|
133 |
msgid "Password change notification to admin"
|
134 |
msgstr "Wijziging wachtwoord notificatie aan sitebeheerder"
|
135 |
|
136 |
-
#:
|
137 |
msgid "Password change notification to user"
|
138 |
msgstr "Wijziging wachtwoord notificatie aan gebruiker"
|
139 |
|
140 |
-
#:
|
141 |
-
msgid "
|
142 |
-
msgstr "
|
143 |
|
144 |
-
#:
|
145 |
msgid "Password forgotten e-mail to user"
|
146 |
msgstr "Wachtwoord vergeten e-mail aan gebruiker"
|
147 |
|
148 |
-
#:
|
149 |
-
msgid "
|
150 |
-
msgstr "
|
151 |
|
152 |
-
#:
|
153 |
-
msgid "
|
154 |
-
msgstr "
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
155 |
|
156 |
-
#:
|
157 |
msgid ""
|
158 |
"Send e-mail to an author (and/or others) of a comment/trackback/pingback on "
|
159 |
"a post."
|
160 |
msgstr ""
|
161 |
-
"Verstuur een e-mail naar de auteur (en/of anderen) van een "
|
162 |
-
"
|
163 |
|
164 |
-
#:
|
165 |
msgid ""
|
166 |
-
"Send e-mail to
|
|
|
167 |
msgstr ""
|
168 |
-
"Verstuur een e-mail naar
|
169 |
-
"
|
170 |
|
171 |
-
#:
|
|
|
|
|
|
|
|
|
|
|
|
|
172 |
msgid ""
|
173 |
"Send e-mail to registered user about changing his or her password. Be "
|
174 |
"careful with this option, because when unchecked, the forgotten password "
|
@@ -179,31 +122,14 @@ msgstr ""
|
|
179 |
"aangevinkt, de vergeten wachtwoord e-mails aanvragen ook worden geblokkeerd "
|
180 |
"en dus niet verzonden."
|
181 |
|
182 |
-
#:
|
183 |
-
msgid "Send e-mail to the blog admin of a user changing his or her password."
|
184 |
-
msgstr ""
|
185 |
-
"Verstuur een e-mail naar de sitebeheerder van een gebruiker welke zijn "
|
186 |
-
"wachtwoord heeft aangepast."
|
187 |
-
|
188 |
-
#: modules/settings-page/views/settings.php:12
|
189 |
msgid ""
|
190 |
-
"Send e-mail to
|
191 |
-
"awaiting approval."
|
192 |
-
msgstr ""
|
193 |
-
"Verstuur een e-mail naar de moderator van het blog over een nieuwe comment "
|
194 |
-
"welke op een goedkeuring wacht."
|
195 |
-
|
196 |
-
#: modules/settings-page/views/settings.php:10
|
197 |
-
msgid "Send e-mail with login credentials to a newly-registered user."
|
198 |
msgstr ""
|
199 |
-
"Verstuur een e-mail
|
200 |
-
"
|
201 |
-
|
202 |
-
#: modules/settings-page/views/settings.php:35
|
203 |
-
msgid "Send the forgotten password e-mail to administrators."
|
204 |
-
msgstr "Verstuur vergeten wachtwoord e-mail aan administratoren"
|
205 |
|
206 |
-
#:
|
207 |
msgid ""
|
208 |
"Send the forgotten password e-mail to registered user.<br/>(To prevent "
|
209 |
"locking yourself out, sending of the forgotten password e-mail for "
|
@@ -211,73 +137,16 @@ msgid ""
|
|
211 |
msgstr ""
|
212 |
"Verstuur het vergeten wachtwoord e-mail naar de geregistreerde gebruiker."
|
213 |
|
214 |
-
#:
|
215 |
-
msgid ""
|
216 |
-
"Sends an e-mail after a successful automatic plugin update to administrators."
|
217 |
-
" E-mails about failed plugin updates will always be sent to the "
|
218 |
-
"administrators"
|
219 |
-
msgstr ""
|
220 |
-
"Verstuurd een e-mail na een succesvolle automatische plugin update aan "
|
221 |
-
"administratoren. e-mails over mislukte plugin updates worden altijd "
|
222 |
-
"verstuurd aan administratoren"
|
223 |
-
|
224 |
-
#: modules/settings-page/views/settings.php:28
|
225 |
-
msgid ""
|
226 |
-
"Sends an e-mail after a successful automatic theme update to administrators. "
|
227 |
-
"E-mails about failed theme updates will always be sent to the administrators"
|
228 |
-
msgstr ""
|
229 |
-
"Verstuurd een e-mail na een succesvolle automatische thema update aan "
|
230 |
-
"administratoren. e-mails over mislukte thema updates worden altijd verstuurd "
|
231 |
-
"aan administratoren"
|
232 |
-
|
233 |
-
#: modules/settings-page/views/settings.php:26
|
234 |
msgid ""
|
235 |
-
"
|
236 |
-
"
|
237 |
-
"
|
238 |
-
|
239 |
-
"
|
240 |
-
|
241 |
-
"
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
"
|
246 |
-
"her e-mailaddress."
|
247 |
-
msgstr ""
|
248 |
-
"Verstuurd een e-mail aan administratoren nadat een gebruiker een aanvraag "
|
249 |
-
"heeft gedaan om zijn e-mailadres aan te passen."
|
250 |
-
|
251 |
-
#: modules/user-email-changed.php:39
|
252 |
-
msgid ""
|
253 |
-
"Sends an e-mail to administrators after a user successfully updated his or "
|
254 |
-
"her e-mailaddress."
|
255 |
-
msgstr ""
|
256 |
-
"Verstuurd een e-mail aan administratoren nadat een gebruiker zijn e-"
|
257 |
-
"mailadres succesvol heeft aangepast."
|
258 |
-
|
259 |
-
#: modules/settings-page/views/settings.php:23
|
260 |
-
msgid "Sends an e-mail to the site admin after a new user is registered."
|
261 |
-
msgstr ""
|
262 |
-
"Verstuur een e-mail naar de sitebeheerder zodra er een nieuwe gebruiker is "
|
263 |
-
"geregistreerd."
|
264 |
-
|
265 |
-
#. Description of the plugin
|
266 |
-
msgid ""
|
267 |
-
"This plugin gives you the option to disable some of the notification e-mails "
|
268 |
-
"send by Wordpress. It's a simple plugin but effective."
|
269 |
-
msgstr ""
|
270 |
-
"Deze plugin geeft de mogelijkheid om sommige notificatie e-mails verstuurd "
|
271 |
-
"door Wordpress aan of uit te zetten. Het is simpel maar effectief."
|
272 |
-
|
273 |
-
#: modules/user-email-changed.php:39
|
274 |
-
msgid "User changed (confirmed) e-mail notification to admin"
|
275 |
-
msgstr "Gebruiker heeft e-mail veranderd notificatie naar de administrator"
|
276 |
-
|
277 |
-
#: modules/settings-page/views/container.php:7
|
278 |
-
msgid "version"
|
279 |
-
msgstr "versie"
|
280 |
-
|
281 |
-
#. Author of the plugin
|
282 |
-
msgid "Virgial Berveling"
|
283 |
-
msgstr "Virgial Berveling"
|
3 |
"Project-Id-Version: Famne\n"
|
4 |
"Report-Msgid-Bugs-To: \n"
|
5 |
"POT-Creation-Date: \n"
|
6 |
+
"PO-Revision-Date: 2018-10-19 22:36+0200\n"
|
7 |
+
"Language-Team: \n"
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=UTF-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
14 |
"_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n"
|
15 |
"X-Poedit-Basepath: ..\n"
|
16 |
"X-Textdomain-Support: yes\n"
|
17 |
+
"X-Generator: Poedit 2.2\n"
|
18 |
"Last-Translator: \n"
|
19 |
+
"Language: nl\n"
|
20 |
"X-Poedit-SearchPath-0: .\n"
|
21 |
|
22 |
+
#: includes/class.FAMNESettingsPage.php:62
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
23 |
msgid "Manage the notification e-mails"
|
24 |
msgstr "Beheer notificatie e-mails"
|
25 |
|
26 |
+
#: includes/class.FAMNESettingsPage.php:73
|
27 |
+
msgid "If you find this plugin useful, you can show your appreciation here :-)"
|
28 |
+
msgstr "Geef een kleine donatie als je deze plugin handig vindt"
|
|
|
|
|
|
|
|
|
29 |
|
30 |
+
#: includes/class.FAMNESettingsPage.php:106
|
31 |
msgid "New user notification to admin"
|
32 |
msgstr "Nieuwe gebruiker notificatie aan sitebeheerder"
|
33 |
|
34 |
+
#: includes/class.FAMNESettingsPage.php:114
|
35 |
msgid "New user notification to user"
|
36 |
msgstr "Nieuwe gebruiker notificatie aan gebruiker"
|
37 |
|
38 |
+
#: includes/class.FAMNESettingsPage.php:122
|
|
|
|
|
|
|
|
|
39 |
msgid "Notify post author"
|
40 |
msgstr "Notificeer bericht schrijver"
|
41 |
|
42 |
+
#: includes/class.FAMNESettingsPage.php:130
|
43 |
+
msgid "Notify moderator"
|
44 |
+
msgstr "Notificeer moderator"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
45 |
|
46 |
+
#: includes/class.FAMNESettingsPage.php:138
|
47 |
msgid "Password change notification to admin"
|
48 |
msgstr "Wijziging wachtwoord notificatie aan sitebeheerder"
|
49 |
|
50 |
+
#: includes/class.FAMNESettingsPage.php:146
|
51 |
msgid "Password change notification to user"
|
52 |
msgstr "Wijziging wachtwoord notificatie aan gebruiker"
|
53 |
|
54 |
+
#: includes/class.FAMNESettingsPage.php:154
|
55 |
+
msgid "E-mail address change notification to user"
|
56 |
+
msgstr "E-mailadres wijziging notificatie aan gebruiker"
|
57 |
|
58 |
+
#: includes/class.FAMNESettingsPage.php:162
|
59 |
msgid "Password forgotten e-mail to user"
|
60 |
msgstr "Wachtwoord vergeten e-mail aan gebruiker"
|
61 |
|
62 |
+
#: includes/class.FAMNESettingsPage.php:170
|
63 |
+
msgid "Password forgotten e-mail to administrator"
|
64 |
+
msgstr "Wachtwoord vergeten e-mail aan sitebeheerder"
|
65 |
|
66 |
+
#: includes/class.FAMNESettingsPage.php:199
|
67 |
+
msgid "Manage your notification e-mail preferences below."
|
68 |
+
msgstr "Beheer hieronder jouw notificatie e-mail voorkeuren."
|
69 |
+
|
70 |
+
#: includes/class.FAMNESettingsPage.php:201
|
71 |
+
msgid "By unchecking the checkbox you prevent sending the specific e-mails."
|
72 |
+
msgstr ""
|
73 |
+
"Door de aanvinkbox niet aan te vinden voorkom je het verzenden van de "
|
74 |
+
"specifieke e-mails."
|
75 |
+
|
76 |
+
#: includes/class.FAMNESettingsPage.php:213
|
77 |
+
msgid "Enable sending e-mail"
|
78 |
+
msgstr "E-mail verzenden activeren"
|
79 |
+
|
80 |
+
#: includes/class.FAMNESettingsPage.php:220
|
81 |
+
msgid "Sends an e-mail to the site admin after a new user is registered."
|
82 |
+
msgstr ""
|
83 |
+
"Verstuur een e-mail naar de sitebeheerder zodra er een nieuwe gebruiker is "
|
84 |
+
"geregistreerd."
|
85 |
+
|
86 |
+
#: includes/class.FAMNESettingsPage.php:225
|
87 |
+
msgid "Send e-mail with login credentials to a newly-registered user."
|
88 |
+
msgstr ""
|
89 |
+
"Verstuur een e-mail met login gegevens naar een nieuw geregistreerde "
|
90 |
+
"gebruiker."
|
91 |
|
92 |
+
#: includes/class.FAMNESettingsPage.php:230
|
93 |
msgid ""
|
94 |
"Send e-mail to an author (and/or others) of a comment/trackback/pingback on "
|
95 |
"a post."
|
96 |
msgstr ""
|
97 |
+
"Verstuur een e-mail naar de auteur (en/of anderen) van een comment/trackback/"
|
98 |
+
"pingback op een bericht."
|
99 |
|
100 |
+
#: includes/class.FAMNESettingsPage.php:235
|
101 |
msgid ""
|
102 |
+
"Send e-mail to the moderator of the blog about a new comment that is "
|
103 |
+
"awaiting approval."
|
104 |
msgstr ""
|
105 |
+
"Verstuur een e-mail naar de moderator van het blog over een nieuwe comment "
|
106 |
+
"welke op een goedkeuring wacht."
|
107 |
|
108 |
+
#: includes/class.FAMNESettingsPage.php:240
|
109 |
+
msgid "Send e-mail to the blog admin of a user changing his or her password."
|
110 |
+
msgstr ""
|
111 |
+
"Verstuur een e-mail naar de sitebeheerder van een gebruiker welke zijn "
|
112 |
+
"wachtwoord heeft aangepast."
|
113 |
+
|
114 |
+
#: includes/class.FAMNESettingsPage.php:245
|
115 |
msgid ""
|
116 |
"Send e-mail to registered user about changing his or her password. Be "
|
117 |
"careful with this option, because when unchecked, the forgotten password "
|
122 |
"aangevinkt, de vergeten wachtwoord e-mails aanvragen ook worden geblokkeerd "
|
123 |
"en dus niet verzonden."
|
124 |
|
125 |
+
#: includes/class.FAMNESettingsPage.php:250
|
|
|
|
|
|
|
|
|
|
|
|
|
126 |
msgid ""
|
127 |
+
"Send e-mail to registered user about changing his or her E-mail address."
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
128 |
msgstr ""
|
129 |
+
"Verstuur een e-mail naar een geregistreerde gebruiker over het aanpassen van "
|
130 |
+
"zijn of haar e-mailadres."
|
|
|
|
|
|
|
|
|
131 |
|
132 |
+
#: includes/class.FAMNESettingsPage.php:255
|
133 |
msgid ""
|
134 |
"Send the forgotten password e-mail to registered user.<br/>(To prevent "
|
135 |
"locking yourself out, sending of the forgotten password e-mail for "
|
137 |
msgstr ""
|
138 |
"Verstuur het vergeten wachtwoord e-mail naar de geregistreerde gebruiker."
|
139 |
|
140 |
+
#: includes/class.FAMNESettingsPage.php:259
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
141 |
msgid ""
|
142 |
+
"Send the forgotten password e-mail to administrators. Okay, this is a "
|
143 |
+
"<strong style=\"color:#900\">DANGEROUS OPTION !</strong><br/> So be warned, "
|
144 |
+
"because unchecking this option prevents sending out the forgotten password e-"
|
145 |
+
"mail to all administrators. So hold on to your own password and uncheck this "
|
146 |
+
"one at your own risk ;-)"
|
147 |
+
msgstr ""
|
148 |
+
"Verstuur het vergeten wachtwoord e-mail aan sitebeheerders. Okee, dit is een "
|
149 |
+
"<strong style=\"color:#900\">GEVAARLIJKE OPTIE !</strong><br/>Dus wees "
|
150 |
+
"gewaarschuwd, omdat bij het niet aanvinken van deze optie het vergeten "
|
151 |
+
"wachtwoord e-mail niet meer wordt verstuurd naar sitebeheerders. Dus houdt "
|
152 |
+
"je wachtwoord bij de hand en vink deze optie uit op eigen risico ;-)"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
languages/manage-notification-emails.pot
CHANGED
@@ -1,247 +1,112 @@
|
|
1 |
-
# Copyright (C) 2021 Manage Notification E-mails
|
2 |
-
# This file is distributed under the same license as the Manage Notification E-mails package.
|
3 |
#, fuzzy
|
4 |
msgid ""
|
5 |
msgstr ""
|
6 |
-
"Project-Id-Version:
|
|
|
|
|
|
|
|
|
|
|
7 |
"MIME-Version: 1.0\n"
|
8 |
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
"Content-Transfer-Encoding: 8bit\n"
|
|
|
|
|
|
|
10 |
"X-Poedit-Basepath: ..\n"
|
11 |
-
"X-
|
12 |
-
"
|
13 |
-
"
|
14 |
"X-Poedit-SearchPath-0: .\n"
|
15 |
-
"X-Poedit-SearchPathExcluded-0: *.js\n"
|
16 |
-
"X-Poedit-SourceCharset: UTF-8\n"
|
17 |
-
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
18 |
-
"Language: \n"
|
19 |
-
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
20 |
-
"POT-Creation-Date: 2021-01-16 13:57+0000\n"
|
21 |
-
"X-Generator: Loco https://localise.biz/"
|
22 |
|
23 |
-
#:
|
24 |
-
msgid "Automatic Wordpress core update e-mail"
|
25 |
-
msgstr ""
|
26 |
-
|
27 |
-
#: modules/settings-page/views/settings.php:27
|
28 |
-
msgid "Automatic Wordpress plugin update e-mail"
|
29 |
-
msgstr ""
|
30 |
-
|
31 |
-
#: modules/settings-page/views/settings.php:28
|
32 |
-
msgid "Automatic Wordpress theme update e-mail"
|
33 |
-
msgstr ""
|
34 |
-
|
35 |
-
#: modules/settings-page/views/extra.php:10
|
36 |
-
msgid "Available Manage Notification E-mail Modules"
|
37 |
-
msgstr ""
|
38 |
-
|
39 |
-
#: modules/settings-page/class.FAMNESettingsPage.php:58
|
40 |
-
msgid "Core options"
|
41 |
-
msgstr ""
|
42 |
-
|
43 |
-
#: modules/settings-page/views/settings.php:14
|
44 |
-
msgid "E-mail address change notification to user"
|
45 |
-
msgstr ""
|
46 |
-
|
47 |
-
#: modules/user-email-changed.php:37
|
48 |
-
msgid "E-mail address changed by user"
|
49 |
-
msgstr ""
|
50 |
-
|
51 |
-
#: modules/custom-recipients.php:37
|
52 |
-
msgid "E-mail address(es)"
|
53 |
-
msgstr ""
|
54 |
-
|
55 |
-
#: modules/custom-recipients.php:35
|
56 |
-
msgid "Extra admin recipients"
|
57 |
-
msgstr ""
|
58 |
-
|
59 |
-
#: modules/settings-page/views/modules.php:8
|
60 |
-
msgid "Extra modules"
|
61 |
-
msgstr ""
|
62 |
-
|
63 |
-
#. Author URI of the plugin
|
64 |
-
msgid "https://www.freeamigos.nl"
|
65 |
-
msgstr ""
|
66 |
-
|
67 |
-
#. URI of the plugin
|
68 |
-
msgid "https://www.freeamigos.nl/wp-plugins/manage-notification-emails/1.7.0"
|
69 |
-
msgstr ""
|
70 |
-
|
71 |
-
#: modules/settings-page/views/container.php:27
|
72 |
-
msgid "If you find this plugin useful, you can show your appreciation here :-)"
|
73 |
-
msgstr ""
|
74 |
-
|
75 |
-
#: modules/settings-page/class.FAMNESettingsPage.php:60
|
76 |
-
#: modules/settings-page/views/extra.php:8
|
77 |
-
msgid "Information"
|
78 |
-
msgstr ""
|
79 |
-
|
80 |
-
#. Name of the plugin
|
81 |
-
msgid "Manage Notification E-mails"
|
82 |
-
msgstr ""
|
83 |
-
|
84 |
-
#: modules/settings-page/views/container.php:7
|
85 |
msgid "Manage the notification e-mails"
|
86 |
msgstr ""
|
87 |
|
88 |
-
#:
|
89 |
-
msgid "
|
90 |
-
msgstr ""
|
91 |
-
|
92 |
-
#: modules/settings-page/class.FAMNESettingsPage.php:59
|
93 |
-
msgid "Modules"
|
94 |
msgstr ""
|
95 |
|
96 |
-
#:
|
97 |
msgid "New user notification to admin"
|
98 |
msgstr ""
|
99 |
|
100 |
-
#:
|
101 |
msgid "New user notification to user"
|
102 |
msgstr ""
|
103 |
|
104 |
-
#:
|
105 |
-
msgid "Notify moderator"
|
106 |
-
msgstr ""
|
107 |
-
|
108 |
-
#: modules/settings-page/views/settings.php:11
|
109 |
msgid "Notify post author"
|
110 |
msgstr ""
|
111 |
|
112 |
-
#:
|
113 |
-
msgid ""
|
114 |
-
"Okay, this is a <strong style=\"color:#900\">DANGEROUS OPTION !</strong><br/>"
|
115 |
-
" So be warned, because unchecking this option prevents sending out the "
|
116 |
-
"forgotten password e-mail to all administrators. So hold on to your own "
|
117 |
-
"password and uncheck this one at your own risk ;-)"
|
118 |
-
msgstr ""
|
119 |
-
|
120 |
-
#: modules/settings-page/views/settings.php:19
|
121 |
-
msgid "Options for e-mails to administrators"
|
122 |
-
msgstr ""
|
123 |
-
|
124 |
-
#: modules/settings-page/views/settings.php:7
|
125 |
-
msgid "Options for e-mails to users"
|
126 |
msgstr ""
|
127 |
|
128 |
-
#:
|
129 |
msgid "Password change notification to admin"
|
130 |
msgstr ""
|
131 |
|
132 |
-
#:
|
133 |
msgid "Password change notification to user"
|
134 |
msgstr ""
|
135 |
|
136 |
-
#:
|
137 |
-
msgid "
|
138 |
msgstr ""
|
139 |
|
140 |
-
#:
|
141 |
msgid "Password forgotten e-mail to user"
|
142 |
msgstr ""
|
143 |
|
144 |
-
#:
|
145 |
-
msgid "
|
146 |
-
msgstr ""
|
147 |
-
|
148 |
-
#: modules/settings-page/views/settings.php:39
|
149 |
-
msgid "Reset settings"
|
150 |
-
msgstr ""
|
151 |
-
|
152 |
-
#: modules/settings-page/views/settings.php:11
|
153 |
-
msgid ""
|
154 |
-
"Send e-mail to an author (and/or others) of a comment/trackback/pingback on "
|
155 |
-
"a post."
|
156 |
msgstr ""
|
157 |
|
158 |
-
#:
|
159 |
-
msgid ""
|
160 |
-
"Send e-mail to registered user about changing his or her E-mail address."
|
161 |
msgstr ""
|
162 |
|
163 |
-
#:
|
164 |
-
msgid ""
|
165 |
-
"Send e-mail to registered user about changing his or her password. Be "
|
166 |
-
"careful with this option, because when unchecked, the forgotten password "
|
167 |
-
"request e-mails will be blocked too."
|
168 |
msgstr ""
|
169 |
|
170 |
-
#:
|
171 |
-
msgid "
|
172 |
msgstr ""
|
173 |
|
174 |
-
#:
|
175 |
-
msgid ""
|
176 |
-
"Send e-mail to the moderator of the blog about a new comment that is "
|
177 |
-
"awaiting approval."
|
178 |
msgstr ""
|
179 |
|
180 |
-
#:
|
181 |
msgid "Send e-mail with login credentials to a newly-registered user."
|
182 |
msgstr ""
|
183 |
|
184 |
-
#:
|
185 |
-
msgid "Send
|
186 |
msgstr ""
|
187 |
|
188 |
-
#:
|
189 |
-
msgid ""
|
190 |
-
"Send the forgotten password e-mail to registered user.<br/>(To prevent "
|
191 |
-
"locking yourself out, sending of the forgotten password e-mail for "
|
192 |
-
"administrators will still work)"
|
193 |
msgstr ""
|
194 |
|
195 |
-
#:
|
196 |
-
msgid ""
|
197 |
-
"Sends an e-mail after a successful automatic plugin update to administrators."
|
198 |
-
" E-mails about failed plugin updates will always be sent to the "
|
199 |
-
"administrators"
|
200 |
-
msgstr ""
|
201 |
-
|
202 |
-
#: modules/settings-page/views/settings.php:28
|
203 |
-
msgid ""
|
204 |
-
"Sends an e-mail after a successful automatic theme update to administrators. "
|
205 |
-
"E-mails about failed theme updates will always be sent to the administrators"
|
206 |
-
msgstr ""
|
207 |
-
|
208 |
-
#: modules/settings-page/views/settings.php:26
|
209 |
-
msgid ""
|
210 |
-
"Sends an e-mail after a successful automatic Wordpress core update to "
|
211 |
-
"administrators. E-mails about failed updates will always be sent to the "
|
212 |
-
"administrators and cannot be disabled."
|
213 |
-
msgstr ""
|
214 |
-
|
215 |
-
#: modules/user-email-changed.php:38
|
216 |
-
msgid ""
|
217 |
-
"Sends an e-mail to administrators after a user requested to update his or "
|
218 |
-
"her e-mailaddress."
|
219 |
-
msgstr ""
|
220 |
-
|
221 |
-
#: modules/user-email-changed.php:39
|
222 |
-
msgid ""
|
223 |
-
"Sends an e-mail to administrators after a user successfully updated his or "
|
224 |
-
"her e-mailaddress."
|
225 |
-
msgstr ""
|
226 |
-
|
227 |
-
#: modules/settings-page/views/settings.php:23
|
228 |
-
msgid "Sends an e-mail to the site admin after a new user is registered."
|
229 |
msgstr ""
|
230 |
|
231 |
-
|
232 |
-
msgid ""
|
233 |
-
"This plugin gives you the option to disable some of the notification e-mails "
|
234 |
-
"send by Wordpress. It's a simple plugin but effective."
|
235 |
msgstr ""
|
236 |
|
237 |
-
#:
|
238 |
-
msgid "
|
239 |
msgstr ""
|
240 |
|
241 |
-
#:
|
242 |
-
msgid "
|
243 |
msgstr ""
|
244 |
|
245 |
-
|
246 |
-
msgid "
|
247 |
-
msgstr ""
|
|
|
|
|
1 |
#, fuzzy
|
2 |
msgid ""
|
3 |
msgstr ""
|
4 |
+
"Project-Id-Version: Famne\n"
|
5 |
+
"Report-Msgid-Bugs-To: \n"
|
6 |
+
"POT-Creation-Date: \n"
|
7 |
+
"PO-Revision-Date: 2018-10-19 21:04:29+0000\n"
|
8 |
+
"Last-Translator: none\n"
|
9 |
+
"Language-Team: \n"
|
10 |
"MIME-Version: 1.0\n"
|
11 |
"Content-Type: text/plain; charset=UTF-8\n"
|
12 |
"Content-Transfer-Encoding: 8bit\n"
|
13 |
+
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
14 |
+
"X-Poedit-SourceCharset: utf-8\n"
|
15 |
+
"X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n"
|
16 |
"X-Poedit-Basepath: ..\n"
|
17 |
+
"X-Textdomain-Support: yes\n"
|
18 |
+
"Language: en_US\n"
|
19 |
+
"X-Generator: Poedit 2.2\n"
|
20 |
"X-Poedit-SearchPath-0: .\n"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
21 |
|
22 |
+
#: includes/class.FAMNESettingsPage.php:62
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
23 |
msgid "Manage the notification e-mails"
|
24 |
msgstr ""
|
25 |
|
26 |
+
#: includes/class.FAMNESettingsPage.php:73
|
27 |
+
msgid "If you find this plugin useful, you can show your appreciation here :-)"
|
|
|
|
|
|
|
|
|
28 |
msgstr ""
|
29 |
|
30 |
+
#: includes/class.FAMNESettingsPage.php:106
|
31 |
msgid "New user notification to admin"
|
32 |
msgstr ""
|
33 |
|
34 |
+
#: includes/class.FAMNESettingsPage.php:114
|
35 |
msgid "New user notification to user"
|
36 |
msgstr ""
|
37 |
|
38 |
+
#: includes/class.FAMNESettingsPage.php:122
|
|
|
|
|
|
|
|
|
39 |
msgid "Notify post author"
|
40 |
msgstr ""
|
41 |
|
42 |
+
#: includes/class.FAMNESettingsPage.php:130
|
43 |
+
msgid "Notify moderator"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
44 |
msgstr ""
|
45 |
|
46 |
+
#: includes/class.FAMNESettingsPage.php:138
|
47 |
msgid "Password change notification to admin"
|
48 |
msgstr ""
|
49 |
|
50 |
+
#: includes/class.FAMNESettingsPage.php:146
|
51 |
msgid "Password change notification to user"
|
52 |
msgstr ""
|
53 |
|
54 |
+
#: includes/class.FAMNESettingsPage.php:154
|
55 |
+
msgid "E-mail address change notification to user"
|
56 |
msgstr ""
|
57 |
|
58 |
+
#: includes/class.FAMNESettingsPage.php:162
|
59 |
msgid "Password forgotten e-mail to user"
|
60 |
msgstr ""
|
61 |
|
62 |
+
#: includes/class.FAMNESettingsPage.php:170
|
63 |
+
msgid "Password forgotten e-mail to administrator"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
64 |
msgstr ""
|
65 |
|
66 |
+
#: includes/class.FAMNESettingsPage.php:199
|
67 |
+
msgid "Manage your notification e-mail preferences below."
|
|
|
68 |
msgstr ""
|
69 |
|
70 |
+
#: includes/class.FAMNESettingsPage.php:201
|
71 |
+
msgid "By unchecking the checkbox you prevent sending the specific e-mails."
|
|
|
|
|
|
|
72 |
msgstr ""
|
73 |
|
74 |
+
#: includes/class.FAMNESettingsPage.php:213
|
75 |
+
msgid "Enable sending e-mail"
|
76 |
msgstr ""
|
77 |
|
78 |
+
#: includes/class.FAMNESettingsPage.php:220
|
79 |
+
msgid "Sends an e-mail to the site admin after a new user is registered."
|
|
|
|
|
80 |
msgstr ""
|
81 |
|
82 |
+
#: includes/class.FAMNESettingsPage.php:225
|
83 |
msgid "Send e-mail with login credentials to a newly-registered user."
|
84 |
msgstr ""
|
85 |
|
86 |
+
#: includes/class.FAMNESettingsPage.php:230
|
87 |
+
msgid "Send e-mail to an author (and/or others) of a comment/trackback/pingback on a post."
|
88 |
msgstr ""
|
89 |
|
90 |
+
#: includes/class.FAMNESettingsPage.php:235
|
91 |
+
msgid "Send e-mail to the moderator of the blog about a new comment that is awaiting approval."
|
|
|
|
|
|
|
92 |
msgstr ""
|
93 |
|
94 |
+
#: includes/class.FAMNESettingsPage.php:240
|
95 |
+
msgid "Send e-mail to the blog admin of a user changing his or her password."
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
96 |
msgstr ""
|
97 |
|
98 |
+
#: includes/class.FAMNESettingsPage.php:245
|
99 |
+
msgid "Send e-mail to registered user about changing his or her password. Be careful with this option, because when unchecked, the forgotten password request e-mails will be blocked too."
|
|
|
|
|
100 |
msgstr ""
|
101 |
|
102 |
+
#: includes/class.FAMNESettingsPage.php:250
|
103 |
+
msgid "Send e-mail to registered user about changing his or her E-mail address."
|
104 |
msgstr ""
|
105 |
|
106 |
+
#: includes/class.FAMNESettingsPage.php:255
|
107 |
+
msgid "Send the forgotten password e-mail to registered user.<br/>(To prevent locking yourself out, sending of the forgotten password e-mail for administrators will still work)"
|
108 |
msgstr ""
|
109 |
|
110 |
+
#: includes/class.FAMNESettingsPage.php:259
|
111 |
+
msgid "Send the forgotten password e-mail to administrators. Okay, this is a <strong style=\"color:#900\">DANGEROUS OPTION !</strong><br/> So be warned, because unchecking this option prevents sending out the forgotten password e-mail to all administrators. So hold on to your own password and uncheck this one at your own risk ;-)"
|
112 |
+
msgstr ""
|
manage-notification-emails.php
CHANGED
@@ -1,9 +1,9 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
Plugin Name: Manage Notification E-mails
|
4 |
-
Plugin URI: https://www.freeamigos.nl/wp-plugins/manage-notification-emails/1.
|
5 |
Description: This plugin gives you the option to disable some of the notification e-mails send by Wordpress. It's a simple plugin but effective.
|
6 |
-
Version: 1.
|
7 |
Author: Virgial Berveling
|
8 |
Author URI: https://www.freeamigos.nl
|
9 |
Text Domain: manage-notification-emails
|
@@ -49,7 +49,7 @@ License: GPLv2
|
|
49 |
derivative work you are developing complies with the license, copyright,
|
50 |
trademark, or if you do not understand the difference between
|
51 |
open source and public domain, contact the original author at:
|
52 |
-
|
53 |
|
54 |
|
55 |
INSTALLATION PROCEDURE:
|
@@ -59,12 +59,9 @@ License: GPLv2
|
|
59 |
|
60 |
if (!defined('ABSPATH')) die();
|
61 |
|
62 |
-
define( 'FA_MNE_VERSION', '1.
|
63 |
define( 'FA_MNE_PLUGIN_BASENAME', plugin_basename( __FILE__ ) );
|
64 |
define( 'FA_MNE_PLUGIN_DIR', untrailingslashit( dirname( __FILE__ ) ) );
|
65 |
-
define( 'FA_MNE_SLUG', 'manage-notification-emails' );
|
66 |
-
|
67 |
-
|
68 |
|
69 |
|
70 |
/**
|
@@ -73,24 +70,30 @@ define( 'FA_MNE_SLUG', 'manage-notification-emails' );
|
|
73 |
* @since 1.0.0
|
74 |
*/
|
75 |
|
76 |
-
include_once(FA_MNE_PLUGIN_DIR.'/
|
77 |
-
include_once(FA_MNE_PLUGIN_DIR.'/core/functions.setup.php' );
|
78 |
-
include_once(FA_MNE_PLUGIN_DIR.'/modules/settings-page/settings-page.php');
|
79 |
-
include_once(FA_MNE_PLUGIN_DIR.'/modules/pluggable/pluggable.php');
|
80 |
-
include_once(FA_MNE_PLUGIN_DIR.'/modules/user-email-changed.php');
|
81 |
-
include_once(FA_MNE_PLUGIN_DIR.'/modules/custom-recipients.php');
|
82 |
|
83 |
-
function fa_mne_init()
|
84 |
-
{
|
85 |
-
new FAMNE();
|
86 |
add_action( 'plugins_loaded', 'FAMNE::update_check');
|
|
|
|
|
|
|
|
|
|
|
87 |
}
|
88 |
|
89 |
-
|
90 |
-
|
91 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
92 |
}
|
93 |
-
register_uninstall_hook(__FILE__, 'fa_mne_uninstall');
|
94 |
|
95 |
fa_mne_init();
|
96 |
|
1 |
<?php
|
2 |
/*
|
3 |
Plugin Name: Manage Notification E-mails
|
4 |
+
Plugin URI: https://www.freeamigos.nl/wp-plugins/manage-notification-emails/1.6.1
|
5 |
Description: This plugin gives you the option to disable some of the notification e-mails send by Wordpress. It's a simple plugin but effective.
|
6 |
+
Version: 1.6.1
|
7 |
Author: Virgial Berveling
|
8 |
Author URI: https://www.freeamigos.nl
|
9 |
Text Domain: manage-notification-emails
|
49 |
derivative work you are developing complies with the license, copyright,
|
50 |
trademark, or if you do not understand the difference between
|
51 |
open source and public domain, contact the original author at:
|
52 |
+
http://www.freeamigos.mx/contact/.
|
53 |
|
54 |
|
55 |
INSTALLATION PROCEDURE:
|
59 |
|
60 |
if (!defined('ABSPATH')) die();
|
61 |
|
62 |
+
define( 'FA_MNE_VERSION', '1.6.1' );
|
63 |
define( 'FA_MNE_PLUGIN_BASENAME', plugin_basename( __FILE__ ) );
|
64 |
define( 'FA_MNE_PLUGIN_DIR', untrailingslashit( dirname( __FILE__ ) ) );
|
|
|
|
|
|
|
65 |
|
66 |
|
67 |
/**
|
70 |
* @since 1.0.0
|
71 |
*/
|
72 |
|
73 |
+
include_once( FA_MNE_PLUGIN_DIR . '/includes/class.FAMNE.php' );
|
|
|
|
|
|
|
|
|
|
|
74 |
|
75 |
+
function fa_mne_init() {
|
|
|
|
|
76 |
add_action( 'plugins_loaded', 'FAMNE::update_check');
|
77 |
+
|
78 |
+
if (is_admin()) :
|
79 |
+
include_once( FA_MNE_PLUGIN_DIR . '/includes/class.FAMNESettingsPage.php' );
|
80 |
+
new FAMNESettingsPage();
|
81 |
+
endif;
|
82 |
}
|
83 |
|
84 |
+
/**
|
85 |
+
* Version switch.
|
86 |
+
*
|
87 |
+
* @since 1.3.0
|
88 |
+
*/
|
89 |
+
global $wp_version;
|
90 |
+
if (version_compare($wp_version, '5.2.0') >= 0) {
|
91 |
+
include_once( FA_MNE_PLUGIN_DIR . '/includes/pluggable-functions-1.5.php' );
|
92 |
+
}elseif (version_compare($wp_version, '4.7.0') >= 0) {
|
93 |
+
include_once( FA_MNE_PLUGIN_DIR . '/includes/pluggable-functions-1.3.php' );
|
94 |
+
}else {
|
95 |
+
include_once( FA_MNE_PLUGIN_DIR . '/includes/pluggable-functions-1.2.php' );
|
96 |
}
|
|
|
97 |
|
98 |
fa_mne_init();
|
99 |
|
modules/custom-recipients.php
DELETED
@@ -1,88 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Manage notification emails settings page class
|
4 |
-
* *
|
5 |
-
* This file is part of the Manage Notification Emails plugin
|
6 |
-
* You can find out more about this plugin at https://www.freeamigos.nl
|
7 |
-
* Copyright (c) 2006-2015 Virgial Berveling
|
8 |
-
*
|
9 |
-
* @package WordPress
|
10 |
-
* @author Virgial Berveling
|
11 |
-
* @copyright 2006-2020
|
12 |
-
*
|
13 |
-
* since: 1.0.0
|
14 |
-
*/
|
15 |
-
// Exit if accessed directly.
|
16 |
-
if ( ! defined( 'ABSPATH' ) ) {
|
17 |
-
exit;
|
18 |
-
}
|
19 |
-
|
20 |
-
function load_mod_famne_custom_recipients()
|
21 |
-
{
|
22 |
-
$famne_options = FAMNE::get_option('famne_options');
|
23 |
-
FAMNE::AddModule('custom_admin_recipients',array(
|
24 |
-
'name' => 'Choose extra recipients for admin notifications',
|
25 |
-
'version'=>'1.0.0',
|
26 |
-
'option_id' =>array('custom_admin_recipients'),
|
27 |
-
'card'=> 'card_famne_custom_admin_recipients'
|
28 |
-
));
|
29 |
-
|
30 |
-
function card_famne_custom_admin_recipients($famne_options)
|
31 |
-
{
|
32 |
-
?>
|
33 |
-
<div class="card">
|
34 |
-
<label class="switch"><div class="slider round <?=(!empty($famne_options['custom_admin_recipients'])?'active':'')?>"><span class="on">ON</span><span class="off">OFF</span></div></label>
|
35 |
-
<h2 class="title"><?php _e('Extra admin recipients','manage-notification-emails')?></h2>
|
36 |
-
<?php _e('Here you can add extra admin recipients who will also receive all admin notifications.')?>
|
37 |
-
<?php print_textbox($famne_options,'custom_admin_recipients', __('E-mail address(es)','manage-notification-emails'), '','For multiple addresses separate by comma.','text','email1@domain.com,email2@otherdomain.com');?>
|
38 |
-
</div>
|
39 |
-
<?php
|
40 |
-
}
|
41 |
-
|
42 |
-
add_filter( 'wp_mail', 'famne_custom_to_admin_mailaddresses' );
|
43 |
-
|
44 |
-
/**
|
45 |
-
* Filter WP_Mail Function to Add Multiple Admin Emails
|
46 |
-
*
|
47 |
-
*/
|
48 |
-
function famne_custom_to_admin_mailaddresses( $args )
|
49 |
-
{
|
50 |
-
|
51 |
-
// If to isn't set (who knows why it wouldn't) return args
|
52 |
-
if( ! isset($args['to']) || empty($args['to']) ) return $args;
|
53 |
-
|
54 |
-
// If TO is an array of emails, means it's probably not an admin email
|
55 |
-
if( is_array( $args['to'] ) ) return $args;
|
56 |
-
if( !empty( $args['cc'] ) ) return $args;
|
57 |
-
|
58 |
-
$admin_email = get_option( 'admin_email' );
|
59 |
-
|
60 |
-
// Check if admin email found in string, as TO could be formatted like 'Administrator <admin@domain.com>',
|
61 |
-
// and if we specifically check if it's just the email, we may miss some admin emails.
|
62 |
-
if( strpos( $args['to'], $admin_email ) !== FALSE )
|
63 |
-
{
|
64 |
-
$famne_options = FAMNE::get_option('famne_options');
|
65 |
-
if (empty($famne_options['custom_admin_recipients'])) return $args;
|
66 |
-
|
67 |
-
|
68 |
-
$emails = array();
|
69 |
-
if (strpos($famne_options['custom_admin_recipients'],',') >0):
|
70 |
-
$emails = explode(',',$famne_options['custom_admin_recipients']);
|
71 |
-
else:
|
72 |
-
$emails = array($famne_options['custom_admin_recipients']);
|
73 |
-
endif;
|
74 |
-
|
75 |
-
if (!empty($args['headers']) && is_string($args['headers'])) $args['headers'] = array($args['headers']);
|
76 |
-
if (!empty($emails )):
|
77 |
-
if (empty($args['headers'])) $args['headers'] = array();
|
78 |
-
foreach($emails as $e):
|
79 |
-
$e = trim($e);
|
80 |
-
if (is_email($e)) $args['headers'][] = 'Cc: '.$e;
|
81 |
-
endforeach;
|
82 |
-
endif;
|
83 |
-
}
|
84 |
-
return $args;
|
85 |
-
}
|
86 |
-
}
|
87 |
-
|
88 |
-
add_action('fa_mne_modules','load_mod_famne_custom_recipients');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/pluggable/pluggable.php
DELETED
@@ -1,17 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
if (!defined('FA_MNE_PLUGIN_DIR')) die();
|
4 |
-
|
5 |
-
/**
|
6 |
-
* Version switch.
|
7 |
-
*
|
8 |
-
* @since 1.3.0
|
9 |
-
*/
|
10 |
-
global $wp_version;
|
11 |
-
if (version_compare($wp_version, '5.2.0') >= 0) {
|
12 |
-
include_once( FA_MNE_PLUGIN_DIR . '/modules/pluggable/pluggable-functions-1.5.php' );
|
13 |
-
}elseif (version_compare($wp_version, '4.7.0') >= 0) {
|
14 |
-
include_once( FA_MNE_PLUGIN_DIR . '/modules/pluggable/pluggable-functions-1.3.php' );
|
15 |
-
}else {
|
16 |
-
include_once( FA_MNE_PLUGIN_DIR . '/modules/pluggable/pluggable-functions-1.2.php' );
|
17 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/settings-page/assets/main.min.css
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
.display-inline-block{display:inline-block}.spacer{height:20px}.section-part{position:relative;margin-bottom:20px;padding:10px 20px;border:1px solid #ccc;background-color:#fff}.section-part.border-warning{background-color:rgba(255,255,255,.5)}.section-part.border-warning .option-container{opacity:1 !important;color:red}.section-part.border-warning .option-container.active{color:inherit}.section-part.extra .dashicons-before:before{font-size:14px}.wrap.page-width{max-width:760px}.modules{position:relative;margin:0;display:flex;flex-wrap:wrap}.modules .card{display:block;max-width:440px;margin:0 15px 15px 0}@media only screen and (max-width: 500px){.modules .card{margin:15px 0}}.sections-container .option-container{opacity:.5;display:block;padding-top:5px;padding-bottom:5px;position:relative;padding-left:30px}.sections-container .option-container.active{opacity:1}.sections-container .option-container input[type=checkbox]{position:absolute;top:20px;left:0px}@media only screen and (max-width: 782px){.sections-container .option-container input[type=checkbox]{left:-7px}}.sections-container .text-container{display:block}.sections-container .text-container input[type=text],.sections-container .text-container input[type=email]{display:block;width:100%;margin:5px 0}.nav-tab{cursor:pointer}.nav-tab .dashicons-before:before{position:relative;top:2px}.nav-tab .dashicons-admin-plugins.active{opacity:1;color:#46b450}.nav-tab .dashicons-admin-plugins.inactive{opacity:1;color:#bd003f}.switch{position:relative;display:block;float:right;right:-17px;width:40px;height:17px;cursor:default}.switch input{display:none}.slider{position:absolute;top:0;left:0;right:0;bottom:0;background-color:rgba(0,0,0,.2);-webkit-transition:.4s;transition:.4s}.slider:before{position:absolute;content:"";height:13px;width:13px;left:2px;bottom:2px;background-color:#fff;-webkit-transition:.2s;transition:.2s}.slider.active{background-color:#76d450}.slider.changing{background-color:#0073aa}.slider.active:before{-webkit-transform:translateX(23px);-ms-transform:translateX(23px);transform:translateX(23px)}.on,.off{color:#fff;position:absolute;top:0;left:5px;width:30px;font-size:8px;font-family:Verdana,sans-serif;text-align:right;user-select:none;-webkit-touch-callout:none;-webkit-user-select:none}.on{text-align:left;display:none}.active .off{display:none}.active .on{display:block}.slider.round{border-radius:17px;width:40px;height:17px}.slider.round:before{border-radius:50%}.donation-box{background-color:rgba(255,255,255,.5);margin-right:10px;padding:40px;text-align:center;color:rgba(0,0,0,.7)}
|
2 |
-
|
3 |
-
/*# sourceMappingURL=main.min.css.map?1610727586142*/
|
|
|
|
|
|
modules/settings-page/assets/main.min.css.map
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
{"version":3,"sources":["webpack://local.freeamigos.nl/./src/manage-notifications-emails/main.scss"],"names":[],"mappings":"AAAA,sBAEE,qBAEF,QAEI,YAKJ,cAEI,kBACA,mBACA,kBACA,sBACA,sBAEA,6BAUI,sCARA,+CAEI,qBACA,UACA,sDACI,cAKZ,6CAEI,eAIR,iBAEI,gBAGJ,SACI,kBACA,SACA,aACA,eACA,eACI,cACA,gBACA,qBACA,0CAJJ,eAKQ,eAOZ,sCAEI,WAOA,cACA,gBACA,mBACA,kBACA,kBAVA,6CACI,UAUJ,2DACI,kBACA,SACA,SACA,0CAJJ,2DAKQ,WAMZ,oCAEI,cAEA,2GAGI,cACA,WACA,aAIR,SAEI,eAEA,kCAEI,kBACA,QAGJ,yCAEI,UACA,cAGJ,2CAEI,UACA,cAOR,QACI,kBACA,cACA,YACA,YACA,WACA,YACA,eAGF,2BAEA,QACE,kBACA,MACA,OACA,QACA,SACA,gCACA,uBACA,eAGF,eACE,kBACA,WACA,YACA,WACA,SACA,WACA,sBACA,uBACA,eAEF,eACE,yBAEF,iBACE,yBAGF,sBACE,mCACA,+BACA,2BAIF,SAEE,WACA,kBACA,MACA,SACA,WACA,cACA,+BACA,iBACA,iBACA,2BACA,yBAEF,IAEE,gBACA,aAGF,0BACA,0BAKA,cACE,mBACA,WACA,YAGF,qBACE,kBAGJ,cACI,sCACA,kBACA,aACA,kBACA,qB","file":"main.min.css?1610727586142","sourcesContent":[".display-inline-block\n{\n display:inline-block;\n}\n.spacer\n{\n height:20px;\n}\n\n\n\n.section-part\n{\n position:relative;\n margin-bottom:20px;\n padding:10px 20px;\n border:1px solid #CCC;\n background-color:#FFF;\n\n &.border-warning\n {\n .option-container\n {\n opacity:1 !important;\n color:#F00;\n &.active{\n color:inherit;\n }\n }\n background-color:rgba(255,2555,255,.5);\n }\n &.extra .dashicons-before:before\n {\n font-size:14px;\n }\n}\n\n.wrap.page-width\n{\n max-width:760px;\n}\n\n.modules{\n position: relative;\n margin:0;\n display:flex;\n flex-wrap: wrap;\n .card{\n display:block;\n max-width:440px;\n margin:0 15px 15px 0;\n @media only screen and (max-width: 500px) {\n margin:15px 0;\n }\n }\n}\n\n\n\n.sections-container .option-container\n {\n opacity:.5;\n &.active{\n opacity:1;\n }\n\n\n\n display:block;\n padding-top:5px;\n padding-bottom:5px;\n position: relative;\n padding-left:30px;\n input[type=checkbox]{\n position: absolute;\n top:20px;\n left:0px;\n @media only screen and (max-width: 782px) {\n left:-7px;\n }\n \n }\n}\n\n.sections-container .text-container\n{\n display: block;\n\n input[type=text],\n input[type=email]\n {\n display: block;\n width:100%;\n margin:5px 0;\n }\n}\n\n.nav-tab \n{\n cursor:pointer;\n\n .dashicons-before:before\n {\n position: relative;\n top:2px;\n }\n\n .dashicons-admin-plugins.active\n {\n opacity:1;\n color:#46b450;\n }\n\n .dashicons-admin-plugins.inactive\n {\n opacity:1;\n color: rgb(189, 0, 63);;\n }\n}\n\n\n\n/*SWITCH */\n.switch {\n position: relative;\n display: block;\n float:right;\n right:-17px;\n width: 40px;\n height: 17px;\n cursor: default;\n }\n \n .switch input {display:none;}\n \n .slider {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-color: rgba(0,0,0,.2);\n -webkit-transition: .4s;\n transition: .4s;\n }\n \n .slider:before {\n position: absolute;\n content: \"\";\n height: 13px;\n width: 13px;\n left: 2px;\n bottom: 2px;\n background-color: white;\n -webkit-transition: .2s;\n transition: .2s;\n }\n .slider.active {\n background-color: #76d450;\n }\n .slider.changing {\n background-color: #0073aa;\n }\n\n .slider.active:before {\n -webkit-transform: translateX(23px);\n -ms-transform: translateX(23px);\n transform: translateX(23px);\n }\n \n /*------ ADDED CSS ---------*/\n .on, .off\n {\n color: white;\n position: absolute;\n top:0;\n left: 5px;\n width:30px;\n font-size: 8px;\n font-family: Verdana, sans-serif;\n text-align:right;\n user-select: none;\n -webkit-touch-callout: none; /* iOS Safari */\n -webkit-user-select: none;\n }\n .on\n {\n text-align:left;\n display: none;\n }\n\n .active .off{ display:none;}\n .active .on{ display:block;}\n\n /*--------- END --------*/\n \n /* Rounded sliders */\n .slider.round {\n border-radius: 17px;\n width:40px;\n height:17px;\n }\n \n .slider.round:before {\n border-radius: 50%;}\n\n\n.donation-box{\n background-color:rgba(255,255,255,.5);\n margin-right:10px;\n padding:40px;\n text-align:center;\n color:rgba(0,0,0,0.7);\n}"],"sourceRoot":""}
|
|
modules/settings-page/assets/main.min.js
DELETED
@@ -1,2 +0,0 @@
|
|
1 |
-
!function(a){var e,n,t="settings",c=document.location.hash.replace("#","");function o(e){a(".sections-container").addClass("hidden"),a("#sections-"+e).removeClass("hidden"),a(".nav-tab-wrapper>a").removeClass("nav-tab-active"),a(".nav-tab-wrapper>a#tab-"+e).addClass("nav-tab-active"),document.location="#"+e}a(window).on("hashchange",(function(){o(c=document.location.hash.replace("#",""))})),document.cookie.length>0&&-1!==(e=document.cookie.indexOf("famnetab="))&&(e+=9,-1===(n=document.cookie.indexOf(";",e))&&(n=document.cookie.length),t=unescape(document.cookie.substring(e,n))),""!==c&&(t=c),a(".sections-container").each((function(){var e=a(this).attr("id").replace("sections-",""),n=a(this).attr("title"),t=a(this).attr("data-icon"),c=a('<a id="tab-'+e+'" class="nav-tab">'+(""!==t?'<span class="dashicons-before '+t+'"></span>':"")+n+"</a>");c.on("click",(function(){document.cookie="famnetab="+e,o(e)})),a(".nav-tab-wrapper").append(c)})),o(t),a(".checkbox-change").on("change",(function(){var e=a(this).closest(".option-container");a(this).is(":checked")?e.addClass("active"):e.removeClass("active")}))}(jQuery);
|
2 |
-
//# sourceMappingURL=main.min.js.map?1610727586142
|
|
|
|
modules/settings-page/assets/main.min.js.map
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
{"version":3,"sources":["webpack://local.freeamigos.nl/./src/manage-notifications-emails/main.js"],"names":["$","cstart","cend","stab","hash","document","location","replace","famneShowTab","tab","addClass","removeClass","window","on","cookie","length","indexOf","unescape","substring","each","slug","this","attr","title","icon","$tab","append","$el","closest","is","jQuery"],"mappings":"CAKE,SAAUA,GACX,IAAIC,EAAQC,EACRC,EAAO,WACPC,EAAOC,SAASC,SAASF,KAAKG,QAAS,IAAK,IAyBhD,SAASC,EAAcC,GACtBT,EAAG,uBAAwBU,SAAU,UACrCV,EAAG,aAAeS,GAAME,YAAa,UACrCX,EAAG,sBAAuBW,YAAa,kBACvCX,EAAG,0BAA4BS,GAAMC,SAAU,kBAC/CL,SAASC,SAAW,IAAMG,EA5B3BT,EAAGY,QAASC,GAAI,cAAc,WAE7BL,EADAJ,EAAOC,SAASC,SAASF,KAAKG,QAAS,IAAK,QAIxCF,SAASS,OAAOC,OAAS,IAEZ,KADjBd,EAASI,SAASS,OAAOE,QAAS,gBAEjCf,GAAkB,GAEH,KADfC,EAAOG,SAASS,OAAOE,QAAS,IAAKf,MAEpCC,EAAOG,SAASS,OAAOC,QAExBZ,EAAOc,SAAUZ,SAASS,OAAOI,UAAWjB,EAAQC,KAKxC,KAATE,IACJD,EAAOC,GAaRJ,EAAG,uBAAwBmB,MAAM,WAChC,IAAIC,EAAOpB,EAAGqB,MAAOC,KAAM,MAAOf,QAAS,YAAa,IACpDgB,EAAQvB,EAAGqB,MAAOC,KAAM,SACxBE,EAAOxB,EAAGqB,MAAOC,KAAM,aAGvBG,EAAOzB,EAAG,cAAgBoB,EAAO,sBAFb,KAATI,EAAc,iCAAmCA,EAAO,YAAc,IAEdD,EAAQ,QAC/EE,EAAKZ,GAAI,SAAS,WACjBR,SAASS,OAAS,YAAcM,EAChCZ,EAAcY,MAEfpB,EAAG,oBAAqB0B,OAAQD,MAG9BjB,EAAcL,GAEdH,EAAE,oBAAoBa,GAAG,UAAS,WAC9B,IAAIc,EAAM3B,EAAEqB,MAAMO,QAAQ,qBAC1B5B,EAAEqB,MAAMQ,GAAG,YAAYF,EAAIjB,SAAS,UAAUiB,EAAIhB,YAAY,aAvDpE,CA0DCmB","file":"main.min.js?1610727586142","sourcesContent":["/* eslint-disable no-var */\n/* eslint-disable no-unused-vars */\n\n\n\n( function( $ ) {\n\tvar cstart, cend;\n\tvar stab = 'settings';\n\tvar hash = document.location.hash.replace( '#', '' );\n\n\t$( window ).on( 'hashchange', function( ) {\n\t\thash = document.location.hash.replace( '#', '' );\n\t\tfamneShowTab( hash );\n\t});\n\n\tif ( document.cookie.length > 0 ) {\n\t\tcstart = document.cookie.indexOf( 'famnetab=' );\n\t\tif ( cstart !== -1 ) {\n\t\t\tcstart = cstart + 9;\n\t\t\tcend = document.cookie.indexOf( ';', cstart );\n\t\t\tif ( cend === -1 ) {\n\t\t\t\tcend = document.cookie.length;\n\t\t\t}\n\t\t\tstab = unescape( document.cookie.substring( cstart, cend ) );\n\t\t}\n\t}\n\n\n\tif ( hash !== '' ) {\n\t\tstab = hash;\n\t}\n\n\n\tfunction famneShowTab( tab ) {\n\t\t$( '.sections-container' ).addClass( 'hidden' );\n\t\t$( '#sections-' + tab ).removeClass( 'hidden' );\n\t\t$( '.nav-tab-wrapper>a' ).removeClass( 'nav-tab-active' );\n\t\t$( '.nav-tab-wrapper>a#tab-' + tab ).addClass( 'nav-tab-active' );\n\t\tdocument.location = '#' + tab;\n\t}\n\n\n\t$( '.sections-container' ).each( function( ) {\n\t\tvar slug = $( this ).attr( 'id' ).replace( 'sections-', '' );\n\t\tvar title = $( this ).attr( 'title' );\n\t\tvar icon = $( this ).attr( 'data-icon' );\n\t\tvar iconhtml = icon !== '' ? '<span class=\"dashicons-before ' + icon + '\"></span>' : '';\n\n\t\tvar $tab = $( '<a id=\"tab-' + slug + '\" class=\"nav-tab\">' + iconhtml + title + '</a>' );\n\t\t$tab.on( 'click', function() {\n\t\t\tdocument.cookie = 'famnetab=' + slug;\n\t\t\tfamneShowTab( slug );\n\t\t});\n\t\t$( '.nav-tab-wrapper' ).append( $tab );\n\t});\n\n famneShowTab( stab );\n\n $('.checkbox-change').on('change',function(){\n var $el = $(this).closest('.option-container');\n $(this).is(':checked')?$el.addClass('active'):$el.removeClass('active');\n });\n\n}( jQuery ) );\n\n"],"sourceRoot":""}
|
|
modules/settings-page/class.FAMNESettingsPage.php
DELETED
@@ -1,211 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Manage notification emails settings page class
|
4 |
-
*
|
5 |
-
* Displays the settings page.
|
6 |
-
*
|
7 |
-
* This file is part of the Manage Notification Emails plugin
|
8 |
-
* You can find out more about this plugin at https://www.freeamigos.nl
|
9 |
-
* Copyright (c) 2006-2015 Virgial Berveling
|
10 |
-
*
|
11 |
-
* @package WordPress
|
12 |
-
* @author Virgial Berveling
|
13 |
-
* @copyright 2006-2015
|
14 |
-
*
|
15 |
-
* version: 1.3.0
|
16 |
-
*/
|
17 |
-
|
18 |
-
if (!class_exists('FAMNESettingsPage')):
|
19 |
-
|
20 |
-
class FAMNESettingsPage
|
21 |
-
{
|
22 |
-
/**
|
23 |
-
* Holds the values to be used in the fields callbacks
|
24 |
-
*/
|
25 |
-
private $options;
|
26 |
-
const MENU_SLUG = 'famne-admin';
|
27 |
-
var $tabs = array();
|
28 |
-
private static $sections = array();
|
29 |
-
|
30 |
-
/**
|
31 |
-
* Start up
|
32 |
-
*/
|
33 |
-
public function __construct()
|
34 |
-
{
|
35 |
-
add_action( 'admin_menu', array( $this, 'add_plugin_page' ) );
|
36 |
-
add_action( 'admin_init', array( $this, 'page_init' ) );
|
37 |
-
if(current_user_can('manage_network_options')) add_action( 'network_admin_menu', array( $this, 'add_plugin_page' ) );
|
38 |
-
|
39 |
-
add_filter( 'plugin_action_links_' . FA_MNE_PLUGIN_BASENAME, array($this,'add_action_links') );
|
40 |
-
add_action( 'init', array( $this, 'famne_load_textdomain') );
|
41 |
-
|
42 |
-
}
|
43 |
-
|
44 |
-
/**
|
45 |
-
* Add options page
|
46 |
-
*/
|
47 |
-
public function add_plugin_page()
|
48 |
-
{
|
49 |
-
// This page will be under "Settings"
|
50 |
-
add_options_page(
|
51 |
-
'Settings Admin',
|
52 |
-
'Notification e-mails',
|
53 |
-
'manage_options',
|
54 |
-
'famne-admin',
|
55 |
-
array( $this, 'print_admin_page' )
|
56 |
-
);
|
57 |
-
|
58 |
-
$this->tabs[10] = array('title'=>__('Core options','manage-notification-emails'),'slug'=>'settings','view_file'=>'settings.php','icon'=>'dashicons-admin-settings');
|
59 |
-
$this->tabs[30] = array('title'=>__('Modules','manage-notification-emails'),'slug'=>'modules','view_file'=>'modules.php','icon'=>'dashicons-admin-plugins');
|
60 |
-
$this->tabs[90] = array('title'=>__('Information','manage-notification-emails'),'slug'=>'extra','view_file'=>'extra.php','icon'=>'dashicons-editor-help');
|
61 |
-
|
62 |
-
add_action( 'admin_init', array( $this, 'load_sections' ) );
|
63 |
-
}
|
64 |
-
|
65 |
-
|
66 |
-
/**
|
67 |
-
* Register and add settings
|
68 |
-
*/
|
69 |
-
public function page_init()
|
70 |
-
{
|
71 |
-
|
72 |
-
register_setting(
|
73 |
-
'famne_option_group', // Option group
|
74 |
-
'famne_options', // Option name
|
75 |
-
array( $this, 'sanitize' ) // Sanitize
|
76 |
-
);
|
77 |
-
|
78 |
-
add_settings_section(
|
79 |
-
'setting_section_id', // ID
|
80 |
-
'', // Title
|
81 |
-
array( $this, 'print_section_info' ), // Callback
|
82 |
-
'famne-admin' // Page
|
83 |
-
);
|
84 |
-
}
|
85 |
-
|
86 |
-
static function IsFAMNE_page()
|
87 |
-
{
|
88 |
-
global $pagenow;
|
89 |
-
return ( $pagenow == 'options-general.php' && isset($_GET['page']) && $_GET['page'] == self::MENU_SLUG );
|
90 |
-
}
|
91 |
-
|
92 |
-
|
93 |
-
public function load_sections()
|
94 |
-
{
|
95 |
-
global $pagenow;
|
96 |
-
if ( !self::IsFAMNE_page() ) return;
|
97 |
-
|
98 |
-
add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_scripts') );
|
99 |
-
}
|
100 |
-
|
101 |
-
|
102 |
-
/**
|
103 |
-
* Sanitize each setting field as needed
|
104 |
-
*
|
105 |
-
* @param array $input Contains all settings fields as array keys
|
106 |
-
*/
|
107 |
-
public function sanitize( $input )
|
108 |
-
{
|
109 |
-
if (empty($input)) $input = array();
|
110 |
-
$new_input = array();
|
111 |
-
|
112 |
-
foreach( $input as $key=>$val )
|
113 |
-
$new_input[$key] = $val == '1'?'1':'';
|
114 |
-
|
115 |
-
foreach(FAMNE::getModules() as $mod):
|
116 |
-
if (!empty($mod->option_id) && is_array($mod->option_id)):
|
117 |
-
foreach($mod->option_id as $m):
|
118 |
-
if (isset($input[$m])) $new_input[$m] = $input[$m];
|
119 |
-
endforeach;
|
120 |
-
endif;
|
121 |
-
endforeach;
|
122 |
-
|
123 |
-
$new_input = apply_filters('famne_sanitize_settings_page',$new_input,$input);
|
124 |
-
return $new_input;
|
125 |
-
}
|
126 |
-
|
127 |
-
|
128 |
-
public function print_admin_page()
|
129 |
-
{
|
130 |
-
global $famne_options;
|
131 |
-
if (!empty($_GET['famne_reset'])):
|
132 |
-
if ($_GET['famne_reset'] == '1'):
|
133 |
-
FAMNE::uninstall();
|
134 |
-
FAMNE::install();
|
135 |
-
echo "<script>document.location='options-general.php?page=famne-admin&famne_reset=2'</script>";
|
136 |
-
exit;
|
137 |
-
endif;
|
138 |
-
endif;
|
139 |
-
|
140 |
-
|
141 |
-
$famne_options = FAMNE::get_option( 'famne_options' );
|
142 |
-
|
143 |
-
foreach($this->tabs as $key=>$tab):
|
144 |
-
self::register_section($tab,$key);
|
145 |
-
endforeach;
|
146 |
-
|
147 |
-
do_action('famne_register_settings_section');
|
148 |
-
include_once dirname(__FILE__).'/views/container.php';
|
149 |
-
}
|
150 |
-
|
151 |
-
static function register_section($section,$ord=99) {
|
152 |
-
self::$sections[$ord] = $section;
|
153 |
-
}
|
154 |
-
|
155 |
-
static function print_sections($output=true)
|
156 |
-
{
|
157 |
-
ksort(self::$sections);
|
158 |
-
foreach (self::$sections as $section)
|
159 |
-
{
|
160 |
-
$icon = !empty($section['icon'])?'data-icon="'.$section['icon'].'"':'';
|
161 |
-
echo PHP_EOL;
|
162 |
-
echo '<div class="sections-container" id="sections-'.$section['slug'].'" title="'.ucfirst(__($section['title'])).'" '.$icon.'>';
|
163 |
-
if (!empty($section['view_file'])):
|
164 |
-
include_once(dirname(__FILE__).'/views/'.basename($section['view_file']));
|
165 |
-
endif;
|
166 |
-
if (!empty($section['html'])) echo $section['html'];
|
167 |
-
echo '</div>';
|
168 |
-
echo PHP_EOL;
|
169 |
-
}
|
170 |
-
}
|
171 |
-
|
172 |
-
public function enqueue_scripts($hook)
|
173 |
-
{
|
174 |
-
|
175 |
-
wp_enqueue_style(
|
176 |
-
'famne-settings-page',
|
177 |
-
plugins_url( '/modules/settings-page/assets/main.min.css', FA_MNE_PLUGIN_BASENAME),
|
178 |
-
null,
|
179 |
-
time()
|
180 |
-
);
|
181 |
-
|
182 |
-
wp_enqueue_script(
|
183 |
-
'famne-settings-page', // Handle.
|
184 |
-
plugins_url( '/modules/settings-page/assets/main.min.js',FA_MNE_PLUGIN_BASENAME),
|
185 |
-
array( 'jquery' ), // Dependencies, defined above.
|
186 |
-
time(), // Version: File modification time.
|
187 |
-
true // Enqueue the script in the footer.
|
188 |
-
);
|
189 |
-
}
|
190 |
-
|
191 |
-
|
192 |
-
|
193 |
-
|
194 |
-
function add_action_links ( $links ) {
|
195 |
-
$mylinks = array(
|
196 |
-
'<a href="' . admin_url( 'options-general.php?page=famne-admin' ) . '">'.__('Settings').'</a>',
|
197 |
-
);
|
198 |
-
return array_merge( $links, $mylinks );
|
199 |
-
}
|
200 |
-
|
201 |
-
/**
|
202 |
-
* Translations.
|
203 |
-
*
|
204 |
-
* @since 1.4.2
|
205 |
-
*/
|
206 |
-
function famne_load_textdomain() {
|
207 |
-
load_plugin_textdomain( FA_MNE_SLUG, false, basename(FA_MNE_PLUGIN_DIR) . '/languages' );
|
208 |
-
}
|
209 |
-
}
|
210 |
-
|
211 |
-
endif;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/settings-page/formfields.php
DELETED
@@ -1,39 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) || ! class_exists( 'FAMNESettingsPage', false ) ) exit;
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
function print_start_table_form()
|
7 |
-
{
|
8 |
-
?><table class="form-table"><tbody><?php
|
9 |
-
}
|
10 |
-
|
11 |
-
function print_end_table_form()
|
12 |
-
{
|
13 |
-
?></tbody></table><?php
|
14 |
-
}
|
15 |
-
|
16 |
-
function print_checkbox($options,$id,$title,$label='',$message='')
|
17 |
-
{
|
18 |
-
$checked = isset( $options[$id]) && $options[$id] =='1' ?true:false;
|
19 |
-
|
20 |
-
print '<div class="option-container '.($checked?'active':'').'">';
|
21 |
-
print '<label><input type="checkbox" name="famne_options['.$id.']" value="1" '.($checked?'checked="checked"':'').' class="checkbox-change"/>';
|
22 |
-
print '<strong>'.$title.'</strong><br/>'.$label;
|
23 |
-
print '</label>';
|
24 |
-
print '<p class="description">'.$message.'</p>';
|
25 |
-
print '</div>';
|
26 |
-
}
|
27 |
-
|
28 |
-
function print_textbox($options,$id,$title,$label='',$message='',$type='text',$placeholder='')
|
29 |
-
{
|
30 |
-
$value = isset( $options[$id]) && !empty($options[$id])?$options[$id]:'';
|
31 |
-
|
32 |
-
print '<div class="text-container '.(!empty($value)?'active':'').'">';
|
33 |
-
print '<br/><strong>'.$title.'</strong><br/>';
|
34 |
-
print '<label><input type="'.$type.'" name="famne_options['.$id.']" placeholder="'.$placeholder.'" value="'.esc_attr($value).'" />';
|
35 |
-
print $label;
|
36 |
-
print '</label>';
|
37 |
-
print '<p class="description">'.$message.'</p>';
|
38 |
-
print '</div>';
|
39 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/settings-page/settings-page.php
DELETED
@@ -1,33 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Manage notification emails settings page class
|
4 |
-
* *
|
5 |
-
* This file is part of the Manage Notification Emails plugin
|
6 |
-
* You can find out more about this plugin at https://www.freeamigos.nl
|
7 |
-
* Copyright (c) 2006-2015 Virgial Berveling
|
8 |
-
*
|
9 |
-
* @package WordPress
|
10 |
-
* @author Virgial Berveling
|
11 |
-
* @copyright 2006-2020
|
12 |
-
*
|
13 |
-
* since: 1.6.0
|
14 |
-
*/
|
15 |
-
// Exit if accessed directly.
|
16 |
-
if ( ! defined( 'ABSPATH' ) ) {
|
17 |
-
exit;
|
18 |
-
}
|
19 |
-
|
20 |
-
function load_mod_famne_settings_page()
|
21 |
-
{
|
22 |
-
if (is_admin()) :
|
23 |
-
FAMNE::AddModule('settings_page',array(
|
24 |
-
'name' => 'Settings page',
|
25 |
-
'version'=>'1.0.0'
|
26 |
-
));
|
27 |
-
|
28 |
-
include_once( FA_MNE_PLUGIN_DIR . '/modules/settings-page/class.FAMNESettingsPage.php' );
|
29 |
-
new FAMNESettingsPage();
|
30 |
-
endif;
|
31 |
-
}
|
32 |
-
|
33 |
-
add_action('fa_mne_modules','load_mod_famne_settings_page');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/settings-page/views/container.php
DELETED
@@ -1,35 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) || ! class_exists( 'FAMNESettingsPage', false ) ) exit;
|
3 |
-
include_once(dirname(__FILE__).'/../formfields.php');
|
4 |
-
global $famne_options;
|
5 |
-
?>
|
6 |
-
<div class="wrap">
|
7 |
-
<h2><?php _e('Manage the notification e-mails','manage-notification-emails')?> <small><small><?php _e('version','manage-notification-emails')?> <?=FA_MNE_VERSION?></small></small></h2>
|
8 |
-
<form method="post" action="options.php?">
|
9 |
-
<?php _e('Manage your notification e-mail preferences below.','manage-notification-emails');?>
|
10 |
-
<br/>
|
11 |
-
<br/>
|
12 |
-
<div class="nav-tab-wrapper"></div>
|
13 |
-
<div class="spacer"></div>
|
14 |
-
<div class="sections-wrapper">
|
15 |
-
<?php
|
16 |
-
// This prints out all hidden setting fields
|
17 |
-
settings_fields( 'famne_option_group' );
|
18 |
-
FAMNESettingsPage::print_sections();
|
19 |
-
?>
|
20 |
-
<?php submit_button();?>
|
21 |
-
</div>
|
22 |
-
<div class="clear"></div>
|
23 |
-
</form>
|
24 |
-
</div>
|
25 |
-
|
26 |
-
<div class="donation-box">
|
27 |
-
<p class="description"><?php _e('If you find this plugin useful, you can show your appreciation here :-)','manage-notification-emails')?></p>
|
28 |
-
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
|
29 |
-
<input type="hidden" name="cmd" value="_s-xclick"/>
|
30 |
-
<input type="hidden" name="hosted_button_id" value="LTZWTLEDPULFE"/>
|
31 |
-
<input type="image" src="https://www.paypalobjects.com/nl_NL/NL/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal"/>
|
32 |
-
<img alt="" border="0" src="https://www.paypalobjects.com/nl_NL/i/scr/pixel.gif" width="1" height="1"/>
|
33 |
-
</form>
|
34 |
-
</div>
|
35 |
-
<div class="clear"></div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/settings-page/views/extra.php
DELETED
@@ -1,21 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) || ! class_exists( 'FAMNE', false ) ) exit;
|
3 |
-
include_once(dirname(__FILE__).'/../formfields.php');
|
4 |
-
global $famne_options;
|
5 |
-
?>
|
6 |
-
|
7 |
-
<div class="wrap page-width">
|
8 |
-
<h3><?php _e('Information','manage-notification-emails')?></h3>
|
9 |
-
<div class="section-part extra">
|
10 |
-
<h3><?php _e('Available Manage Notification E-mail Modules','manage-notification-emails');?></h3>
|
11 |
-
<ul>
|
12 |
-
<?php
|
13 |
-
$modules = FAMNE::getModules();
|
14 |
-
foreach($modules as $module):
|
15 |
-
$icon = $module->licensed?'dashicons-products"':'dashicons-admin-plugins';
|
16 |
-
?>
|
17 |
-
<li><span class="dashicons-before <?=$icon?>"></span><?=$module->name?> (<?=$module->version?>)</li>
|
18 |
-
<?php endforeach; ?>
|
19 |
-
</ul>
|
20 |
-
</div>
|
21 |
-
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/settings-page/views/modules.php
DELETED
@@ -1,15 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) || ! class_exists( 'FAMNESettingsPage', false ) ) exit;
|
3 |
-
include_once(dirname(__FILE__).'/../formfields.php');
|
4 |
-
global $famne_options;
|
5 |
-
?>
|
6 |
-
|
7 |
-
<div class="wrap">
|
8 |
-
<h3><?php _e('Extra modules','manage-notification-emails')?></h3>
|
9 |
-
<div class="modules">
|
10 |
-
<?php foreach(FAMNE::getModules() as $mod):
|
11 |
-
if (!in_array($mod->slug,array('pluggable','settings_page')) && !empty($mod->card)) call_user_func($mod->card,$famne_options);
|
12 |
-
endforeach;
|
13 |
-
?>
|
14 |
-
</div>
|
15 |
-
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/settings-page/views/settings.php
DELETED
@@ -1,47 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) || ! class_exists( 'FAMNESettingsPage', false ) ) exit;
|
3 |
-
include_once(dirname(__FILE__).'/../formfields.php');
|
4 |
-
global $famne_options;
|
5 |
-
?>
|
6 |
-
<div class="wrap page-width">
|
7 |
-
<h3><?php _e('Options for e-mails to users','manage-notification-emails')?></h3>
|
8 |
-
<div class="section-part">
|
9 |
-
<?php
|
10 |
-
print_checkbox($famne_options,'wp_new_user_notification_to_user', __('New user notification to user','manage-notification-emails'), __('Send e-mail with login credentials to a newly-registered user.','manage-notification-emails'));
|
11 |
-
print_checkbox($famne_options,'wp_notify_postauthor', __('Notify post author','manage-notification-emails'), __('Send e-mail to an author (and/or others) of a comment/trackback/pingback on a post.','manage-notification-emails'));
|
12 |
-
print_checkbox($famne_options,'wp_notify_moderator', __('Notify moderator','manage-notification-emails'), __('Send e-mail to the moderator of the blog about a new comment that is awaiting approval.','manage-notification-emails'));
|
13 |
-
print_checkbox($famne_options,'send_password_change_email', __('Password change notification to user','manage-notification-emails'), __('Send e-mail to registered user about changing his or her password. Be careful with this option, because when unchecked, the forgotten password request e-mails will be blocked too.','manage-notification-emails'));
|
14 |
-
print_checkbox($famne_options,'send_email_change_email', __('E-mail address change notification to user','manage-notification-emails'), __('Send e-mail to registered user about changing his or her E-mail address.','manage-notification-emails'));
|
15 |
-
print_checkbox($famne_options,'send_password_forgotten_email', __('Password forgotten e-mail to user','manage-notification-emails'), __('Send the forgotten password e-mail to registered user.<br/>(To prevent locking yourself out, sending of the forgotten password e-mail for administrators will still work)','manage-notification-emails'));
|
16 |
-
?>
|
17 |
-
</div>
|
18 |
-
<br/>
|
19 |
-
<h2><?php _e('Options for e-mails to administrators','manage-notification-emails')?></h2>
|
20 |
-
<div class="section-part">
|
21 |
-
<?php
|
22 |
-
print_start_table_form();
|
23 |
-
print_checkbox($famne_options,'wp_new_user_notification_to_admin', __('New user notification to admin','manage-notification-emails'), __('Sends an e-mail to the site admin after a new user is registered.','manage-notification-emails'));
|
24 |
-
print_checkbox($famne_options,'wp_password_change_notification', __('Password change notification to admin','manage-notification-emails'), __('Send e-mail to the blog admin of a user changing his or her password.','manage-notification-emails'));
|
25 |
-
|
26 |
-
print_checkbox($famne_options,'auto_core_update_send_email', __('automatic Wordpress core update e-mail','manage-notification-emails'), __('Sends an e-mail after a successful automatic Wordpress core update to administrators. E-mails about failed updates will always be sent to the administrators and cannot be disabled.','manage-notification-emails'));
|
27 |
-
print_checkbox($famne_options,'auto_plugin_update_send_email', __('Automatic Wordpress plugin update e-mail','manage-notification-emails'), __('Sends an e-mail after a successful automatic plugin update to administrators. E-mails about failed plugin updates will always be sent to the administrators','manage-notification-emails'));
|
28 |
-
print_checkbox($famne_options,'auto_theme_update_send_email', __('Automatic Wordpress theme update e-mail','manage-notification-emails'), __('Sends an e-mail after a successful automatic theme update to administrators. E-mails about failed theme updates will always be sent to the administrators','manage-notification-emails'));
|
29 |
-
print_end_table_form();
|
30 |
-
?>
|
31 |
-
</div>
|
32 |
-
<div class="section-part border-warning">
|
33 |
-
<?php
|
34 |
-
print_start_table_form();
|
35 |
-
print_checkbox($famne_options,'send_password_admin_forgotten_email', __('Password forgotten e-mail to administrator','manage-notification-emails'), __('Send the forgotten password e-mail to administrators.','manage-notification-emails'),__('Okay, this is a <strong style="color:#900">DANGEROUS OPTION !</strong><br/> So be warned, because unchecking this option prevents sending out the forgotten password e-mail to all administrators. So hold on to your own password and uncheck this one at your own risk ;-)','manage-notification-emails'));
|
36 |
-
print_end_table_form();
|
37 |
-
?>
|
38 |
-
</div>
|
39 |
-
<p style="float:right"><a href="#" onclick="resetToDefaults();return false" class="button"><?php _e('Reset settings','manage-notification-emails')?></a></p>
|
40 |
-
</div>
|
41 |
-
<script>
|
42 |
-
function resetToDefaults(){
|
43 |
-
var r = confirm('reset to default settings?');
|
44 |
-
if (r == true) document.location='options-general.php?page=famne-admin&famne_reset=1';
|
45 |
-
}
|
46 |
-
</script>
|
47 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
modules/settings-page/views/sidebar.php
DELETED
File without changes
|
modules/user-email-changed.php
DELETED
@@ -1,117 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Manage notification emails settings page class
|
4 |
-
* *
|
5 |
-
* This file is part of the Manage Notification Emails plugin
|
6 |
-
* You can find out more about this plugin at https://www.freeamigos.nl
|
7 |
-
* Copyright (c) 2006-2015 Virgial Berveling
|
8 |
-
*
|
9 |
-
* @package WordPress
|
10 |
-
* @author Virgial Berveling
|
11 |
-
* @copyright 2006-2020
|
12 |
-
*
|
13 |
-
* since: 1.7.0
|
14 |
-
*/
|
15 |
-
// Exit if accessed directly.
|
16 |
-
if ( ! defined( 'ABSPATH' ) ) {
|
17 |
-
exit;
|
18 |
-
}
|
19 |
-
|
20 |
-
function load_mod_famne_user_email_changed()
|
21 |
-
{
|
22 |
-
$famne_options = FAMNE::get_option('famne_options');
|
23 |
-
FAMNE::AddModule('email_changed_email',array(
|
24 |
-
'name' => 'Add user e-mailaddress change notifier',
|
25 |
-
'version'=>'1.0.0',
|
26 |
-
'option_id' =>array('send_email_change_request_email_to_admin','send_email_changed_email_to_admin'),
|
27 |
-
'card'=> 'card_famne_user_email_changed'
|
28 |
-
));
|
29 |
-
|
30 |
-
|
31 |
-
function card_famne_user_email_changed($famne_options)
|
32 |
-
{
|
33 |
-
$active = !empty($famne_options['send_email_change_request_email_to_admin']) || !empty($famne_options['send_email_changed_email_to_admin']);
|
34 |
-
?>
|
35 |
-
<div class="card">
|
36 |
-
<label class="switch"><div class="slider round <?=($active?'active':'')?>"><span class="on">ON</span><span class="off">OFF</span></div></label>
|
37 |
-
<h2 class="title"><?php _e('E-mail address changed by user','manage-notification-emails')?></h2>
|
38 |
-
<?php print_checkbox($famne_options,'send_email_change_request_email_to_admin', __('Request to change e-mailadress notification to admin','manage-notification-emails'), __('Sends an e-mail to administrators after a user requested to update his or her e-mailaddress.','manage-notification-emails'));?>
|
39 |
-
<?php print_checkbox($famne_options,'send_email_changed_email_to_admin', __('User changed (confirmed) e-mail notification to admin','manage-notification-emails'), __('Sends an e-mail to administrators after a user successfully updated his or her e-mailaddress.','manage-notification-emails'));?>
|
40 |
-
</div>
|
41 |
-
<?php
|
42 |
-
}
|
43 |
-
|
44 |
-
if (!empty($famne_options['send_email_change_request_email_to_admin'])):
|
45 |
-
|
46 |
-
function famne_user_email_change_request_to_admin()
|
47 |
-
{
|
48 |
-
// stop if email not right
|
49 |
-
if ( !is_email( $_POST['email'] ) || email_exists( $_POST['email'] )) return;
|
50 |
-
|
51 |
-
$blog_name = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES );
|
52 |
-
$admin_email = get_option( 'admin_email' );
|
53 |
-
|
54 |
-
/* translators: Do not translate USERNAME, ADMIN_EMAIL, EMAIL, SITENAME, SITEURL: those are placeholders. */
|
55 |
-
$email_text = __(
|
56 |
-
'Howdy admin,
|
57 |
-
|
58 |
-
Recently a user requested to have his email address on his account changed.
|
59 |
-
|
60 |
-
An email change request has been sent to ###EMAIL###
|
61 |
-
|
62 |
-
Regards,
|
63 |
-
All at ###SITENAME###
|
64 |
-
###SITEURL###'
|
65 |
-
);
|
66 |
-
|
67 |
-
|
68 |
-
$email_text = str_replace( '###EMAIL###', $_POST['email'], $email_text );
|
69 |
-
$email_text = str_replace( '###SITENAME###', $blog_name, $email_text );
|
70 |
-
$email_text = str_replace( '###SITEURL###', home_url(), $email_text );
|
71 |
-
|
72 |
-
wp_mail( $admin_email, sprintf( __( '[%s] User requested Email Change' ), $blog_name ), $email_text );
|
73 |
-
|
74 |
-
//return original because we only use the filter to tap in
|
75 |
-
return $org_email_text;
|
76 |
-
}
|
77 |
-
add_action( 'personal_options_update', 'famne_user_email_change_request_to_admin' );
|
78 |
-
|
79 |
-
endif;
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
if (!empty($famne_options['send_email_changed_email_to_admin'])):
|
84 |
-
|
85 |
-
function famne_user_email_changed_email_to_admin($email_change_email, $user, $userdata )
|
86 |
-
{
|
87 |
-
$blog_name = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES );
|
88 |
-
$admin_email = get_option( 'admin_email' );
|
89 |
-
|
90 |
-
/* translators: Do not translate USERNAME, ADMIN_EMAIL, NEW_EMAIL, EMAIL, SITENAME, SITEURL: those are placeholders. */
|
91 |
-
$email_text = __(
|
92 |
-
'Hi admin,
|
93 |
-
|
94 |
-
This notice confirms that the user ###USERNAME### changed his email address on ###SITENAME### from ###EMAIL### to ###NEW_EMAIL###.
|
95 |
-
|
96 |
-
Regards,
|
97 |
-
All at ###SITENAME###
|
98 |
-
###SITEURL###'
|
99 |
-
);
|
100 |
-
|
101 |
-
$email_text = str_replace( '###USERNAME###', $user['user_login'], $email_text );
|
102 |
-
$email_text = str_replace( '###NEW_EMAIL###', $userdata['user_email'], $email_text );
|
103 |
-
$email_text = str_replace( '###EMAIL###', $user['user_email'], $email_text );
|
104 |
-
$email_text = str_replace( '###SITENAME###', $blog_name, $email_text );
|
105 |
-
$email_text = str_replace( '###SITEURL###', home_url(), $email_text );
|
106 |
-
|
107 |
-
wp_mail( $admin_email, sprintf( __( '[%s] User Email Changed' ), $blog_name ), $email_text, $email_change_email['headers'] );
|
108 |
-
|
109 |
-
return $email_change_email;
|
110 |
-
}
|
111 |
-
|
112 |
-
add_filter( 'email_change_email', 'famne_user_email_changed_email_to_admin',10,3);
|
113 |
-
|
114 |
-
endif;
|
115 |
-
}
|
116 |
-
|
117 |
-
add_action('fa_mne_modules','load_mod_famne_user_email_changed');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
readme.txt
CHANGED
@@ -1,9 +1,9 @@
|
|
1 |
=== Plugin Name ===
|
2 |
-
Contributors:
|
3 |
Tags: notification,notify,email,user,password,moderator,postauthor,automatic updates, admin e-mail,switch
|
4 |
Requires at least: 4.0.0
|
5 |
Donate link:https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=TYG56SLWNG42N
|
6 |
-
Tested up to: 5.
|
7 |
Stable tag: 1.6.1
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
1 |
=== Plugin Name ===
|
2 |
+
Contributors: virgial
|
3 |
Tags: notification,notify,email,user,password,moderator,postauthor,automatic updates, admin e-mail,switch
|
4 |
Requires at least: 4.0.0
|
5 |
Donate link:https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=TYG56SLWNG42N
|
6 |
+
Tested up to: 5.7
|
7 |
Stable tag: 1.6.1
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
screen-1.png
ADDED
Binary file
|
screenshot-1.png
DELETED
Binary file
|
screenshot-2.png
DELETED
Binary file
|