Password Protected - Version 2.5.3

Version Description

  • Improved Settings HTML structure
  • Added Note regarding compatibility with login designer within dashboard
Download this release

Release Info

Developer wpexpertsio
Plugin Icon 128x128 Password Protected
Version 2.5.3
Comparing to
See all releases

Code changes from version 2.5.2 to 2.5.3

CHANGELOG.md CHANGED
@@ -2,7 +2,11 @@
2
  All notable changes to this project will be documented in this file.
3
  This project adheres to [Semantic Versioning](http://semver.org/).
4
 
5
- ### 2.5.2 - 2022-05-26
 
 
 
 
6
  Made compatibility with [login designer](https://wp.org/plugins/login-designer); Now you can customize the password-protected screen with the customizer using login designer plugin.
7
 
8
  ## [2.5] - 2021-09-01
2
  All notable changes to this project will be documented in this file.
3
  This project adheres to [Semantic Versioning](http://semver.org/).
4
 
5
+ ## 2.5.3 - 2022-06-17
6
+ - Improved Settings HTML structure
7
+ - Added Note regarding compatibility with login designer within dashboard
8
+
9
+ ## 2.5.2 - 2022-05-26
10
  Made compatibility with [login designer](https://wp.org/plugins/login-designer); Now you can customize the password-protected screen with the customizer using login designer plugin.
11
 
12
  ## [2.5] - 2021-09-01
README.md CHANGED
@@ -72,6 +72,9 @@ If you would like to translate this plugin you can easily contribute at the [Tra
72
 
73
  Upgrade Notice
74
  --------------
 
 
 
75
 
76
  ### 2.5.2
77
  Made compatibility with [login designer](https://wp.org/plugins/login-designer); Now you can customize the password-protected screen with the customizer using login designer plugin.
72
 
73
  Upgrade Notice
74
  --------------
75
+ ### 2.5.3
76
+ - Improved Settings HTML structure
77
+ - Added Note regarding compatibility with login designer within dashboard
78
 
79
  ### 2.5.2
80
  Made compatibility with [login designer](https://wp.org/plugins/login-designer); Now you can customize the password-protected screen with the customizer using login designer plugin.
admin/admin-caching.php CHANGED
@@ -46,7 +46,7 @@ class Password_Protected_Admin_Caching {
46
  // Caching Section
47
  add_settings_section(
48
  'password_protected_compat_caching',
49
- __( 'Caching', 'password-protected' ),
50
  array( $this, 'section_caching' ),
51
  'password-protected-compat'
52
  );
46
  // Caching Section
47
  add_settings_section(
48
  'password_protected_compat_caching',
49
+ __( 'Having issue with Caching?', 'password-protected' ),
50
  array( $this, 'section_caching' ),
51
  'password-protected-compat'
52
  );
admin/admin.php CHANGED
@@ -20,9 +20,20 @@ class Password_Protected_Admin {
20
  add_filter( 'plugin_row_meta', array( $this, 'plugin_row_meta' ), 10, 4 );
21
  add_filter( 'plugin_action_links_password-protected/password-protected.php', array( $this, 'plugin_action_links' ) );
22
  add_filter( 'pre_update_option_password_protected_password', array( $this, 'pre_update_option_password_protected_password' ), 10, 2 );
23
-
24
  }
25
 
 
 
 
 
 
 
 
 
 
 
 
26
  /**
27
  * Add Privacy Policy
28
  */
@@ -65,7 +76,13 @@ class Password_Protected_Admin {
65
  ?>
66
  <p class="submit"><input type="submit" name="submit" id="submit" class="button button-primary" value="<?php _e( 'Save Changes' ) ?>"></p>
67
  </form>
68
- <?php do_settings_sections( 'password-protected-compat' ); ?>
 
 
 
 
 
 
69
  </div>
70
 
71
  <?php
@@ -163,6 +180,13 @@ class Password_Protected_Admin {
163
  'password_protected'
164
  );
165
 
 
 
 
 
 
 
 
166
  register_setting( $this->options_group, 'password_protected_status', 'intval' );
167
  register_setting( $this->options_group, 'password_protected_feeds', 'intval' );
168
  register_setting( $this->options_group, 'password_protected_rest', 'intval' );
@@ -175,6 +199,17 @@ class Password_Protected_Admin {
175
 
176
  }
177
 
 
 
 
 
 
 
 
 
 
 
 
178
  /**
179
  * Sanitize Password Field Input
180
  *
20
  add_filter( 'plugin_row_meta', array( $this, 'plugin_row_meta' ), 10, 4 );
21
  add_filter( 'plugin_action_links_password-protected/password-protected.php', array( $this, 'plugin_action_links' ) );
22
  add_filter( 'pre_update_option_password_protected_password', array( $this, 'pre_update_option_password_protected_password' ), 10, 2 );
23
+ add_action( 'admin_enqueue_scripts', array( $this, 'admin_enqueue_scripts' ) );
24
  }
25
 
26
+ /**
27
+ * Admin enqueue scripts.
28
+ *
29
+ * @param string $hooks Page Hook.
30
+ */
31
+ public function admin_enqueue_scripts( $hooks ) {
32
+ if ( 'settings_page_password-protected' === $hooks ) {
33
+ wp_enqueue_style( 'password-protected-page-script', PASSWORD_PROTECTED_URL . 'assets/css/admin.css', array(), '2.5.3' );
34
+ }
35
+ }
36
+
37
  /**
38
  * Add Privacy Policy
39
  */
76
  ?>
77
  <p class="submit"><input type="submit" name="submit" id="submit" class="button button-primary" value="<?php _e( 'Save Changes' ) ?>"></p>
78
  </form>
79
+ <div id="login-designer-message">
80
+ <?php do_settings_sections( 'password-protected-login-designer' ); ?>
81
+ </div>
82
+
83
+ <div id="help-notice">
84
+ <?php do_settings_sections( 'password-protected-compat' ); ?>
85
+ </div>
86
  </div>
87
 
88
  <?php
180
  'password_protected'
181
  );
182
 
183
+ add_settings_section(
184
+ 'password-protected-login-designer',
185
+ '',
186
+ array( $this, 'login_designer_message' ),
187
+ 'password-protected-login-designer'
188
+ );
189
+
190
  register_setting( $this->options_group, 'password_protected_status', 'intval' );
191
  register_setting( $this->options_group, 'password_protected_feeds', 'intval' );
192
  register_setting( $this->options_group, 'password_protected_rest', 'intval' );
199
 
200
  }
201
 
202
+ /**
203
+ * Login Designer Message
204
+ */
205
+ function login_designer_message(){
206
+ echo '<h3>
207
+ 🎨' . esc_attr__( 'Now you can customize your Password Protected screen with the', 'password-protected' ) . ' <a href="https://wp.org/plugins/login-designer/">Login Designer plugin</a>🌈
208
+ <br>
209
+ 👉<a href="https://wp.org/plugins/login-designer">' . esc_attr__( 'Try it now! It\'s Free.', 'password-protected' ) . '</a>
210
+ </h3>';
211
+ }
212
+
213
  /**
214
  * Sanitize Password Field Input
215
  *
assets/css/admin.css ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ #help-notice {
2
+ margin-top: 10px;
3
+ }
4
+
5
+ #help-notice, #login-designer-message {
6
+ background: white;
7
+ border: #9d9d9d 1px solid;
8
+ padding: 0px 20px;
9
+ }
password-protected.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Password Protected
4
  Plugin URI: https://wordpress.org/plugins/password-protected/
5
  Description: A very simple way to quickly password protect your WordPress site with a single password. Please note: This plugin does not restrict access to uploaded files and images and does not work with some caching setups.
6
- Version: 2.5.2
7
  Author: WPExperts
8
  Text Domain: password-protected
9
  Author URI: https://wpexperts.io/
@@ -39,7 +39,7 @@ $Password_Protected = new Password_Protected();
39
 
40
  class Password_Protected {
41
 
42
- var $version = '2.5.2';
43
  var $admin = null;
44
  var $errors = null;
45
 
3
  Plugin Name: Password Protected
4
  Plugin URI: https://wordpress.org/plugins/password-protected/
5
  Description: A very simple way to quickly password protect your WordPress site with a single password. Please note: This plugin does not restrict access to uploaded files and images and does not work with some caching setups.
6
+ Version: 2.5.3
7
  Author: WPExperts
8
  Text Domain: password-protected
9
  Author URI: https://wpexperts.io/
39
 
40
  class Password_Protected {
41
 
42
+ var $version = '2.5.3';
43
  var $admin = null;
44
  var $errors = null;
45
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: password, protect, password protect, login
4
  Requires at least: 4.6
5
  Tested up to: 6.0
6
  Requires PHP: 5.6
7
- Stable tag: 2.5.2
8
  License: GPLv2 or later
9
 
10
  A very simple way to quickly password protect your WordPress site with a single password.
@@ -24,24 +24,6 @@ Features include:
24
 
25
  > Please note, this plugin works by setting a cookie to allow access to the site. If you are using a caching plugin or web hosting such as WP Engine that has in-built caching, you will need to configure the caching service to be disabled if the Password Protected cookie is set.
26
 
27
- = Customize your website’s login page with Login Designer. =
28
-
29
- [Login Designer](https://wordpress.org/plugins/login-designer/) is the best login customizer plugin for WordPress. It offers contextually displayed options and plugin settings, Custom event triggers, Context-aware previews, powerful custom controls, Live editing…. the list goes on.
30
-
31
- = LOGIN DESIGNER FEATURES =
32
-
33
- * Login error messages customization.
34
- * WordPress login translation.
35
- * Added enable/disable button in customizer for a language translator.
36
- * Added pencil icons on editable settings.
37
- * Customize the background color, radius, padding, shadow, transparency, and checkbox width.
38
- * Edit the text, font, size, and color of username and password fields.
39
- * Customize the full display appearance of the login form input fields.
40
- * Customize the “Remember me” checkbox input element and on the login form.
41
- * Customize the full display appearance of the login submit button.
42
- * Import & Export settings by custom CSS.
43
- * Google ReCaptcha settings.
44
-
45
  = Translations =
46
 
47
  If you would like to translate this plugin you can easily contribute at the [Translating WordPress](https://translate.wordpress.org/projects/wp-plugins/password-protected/) page. The stable plugin needs to be 95% translated for a language file to be available to download/update via WordPress.
@@ -100,6 +82,9 @@ If you would like to translate this plugin you can easily contribute at the [Tra
100
  2. Password Protected settings page.
101
 
102
  == Changelog ==
 
 
 
103
 
104
  = 2.5.2 =
105
  - Made compatibility with [login designer](https://wp.org/plugins/login-designer); Now you can customize the password-protected screen with the customizer using login designer plugin.
4
  Requires at least: 4.6
5
  Tested up to: 6.0
6
  Requires PHP: 5.6
7
+ Stable tag: 2.5.3
8
  License: GPLv2 or later
9
 
10
  A very simple way to quickly password protect your WordPress site with a single password.
24
 
25
  > Please note, this plugin works by setting a cookie to allow access to the site. If you are using a caching plugin or web hosting such as WP Engine that has in-built caching, you will need to configure the caching service to be disabled if the Password Protected cookie is set.
26
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
27
  = Translations =
28
 
29
  If you would like to translate this plugin you can easily contribute at the [Translating WordPress](https://translate.wordpress.org/projects/wp-plugins/password-protected/) page. The stable plugin needs to be 95% translated for a language file to be available to download/update via WordPress.
82
  2. Password Protected settings page.
83
 
84
  == Changelog ==
85
+ = 2.5.3 =
86
+ - Improved Settings HTML structure
87
+ - Added Note regarding compatibility with login designer within dashboard
88
 
89
  = 2.5.2 =
90
  - Made compatibility with [login designer](https://wp.org/plugins/login-designer); Now you can customize the password-protected screen with the customizer using login designer plugin.