Rename wp-login.php - Version 1.9

Version Description

  • wp-admin will now have a wp_die() message instead of a 404 template because this caused problems.
  • Minimum version is now 3.8.
  • Added updates from wp-login.php in 3.8.
Download this release

Release Info

Developer avryl
Plugin Icon 128x128 Rename wp-login.php
Version 1.9
Comparing to
See all releases

Code changes from version 1.8 to 1.9

Files changed (4) hide show
  1. readme.md +10 -4
  2. readme.txt +10 -4
  3. rename-wp-login.php +3 -5
  4. rwl-login.php +16 -10
readme.md CHANGED
@@ -2,9 +2,9 @@
2
 
3
  **Contributors:** avryl
4
  **Tags:** rename, login, wp-login, wp-login.php, brute force attacks, custom login url
5
- **Requires at least:** 3.7
6
- **Tested up to:** 3.7.1
7
- **Stable tag:** 1.8
8
  **License:** GPLv2 or later
9
  **License URI:** http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -17,7 +17,7 @@ Please bookmark or remember your login url, accessing wp-login.php or wp-admin w
17
 
18
  ### Compatibility
19
 
20
- Requires WordPress 3.7 or higher. The registration form, lost password form, login widget and expired sessions will keep working.
21
 
22
  Compatible with plugins like:
23
 
@@ -60,6 +60,12 @@ Either go to your MySQL database and look for the value of `rwl_page` in the opt
60
 
61
  ## Changelog
62
 
 
 
 
 
 
 
63
  ### 1.8
64
 
65
  * OOP PHP.
2
 
3
  **Contributors:** avryl
4
  **Tags:** rename, login, wp-login, wp-login.php, brute force attacks, custom login url
5
+ **Requires at least:** 3.8
6
+ **Tested up to:** 3.8
7
+ **Stable tag:** 1.9
8
  **License:** GPLv2 or later
9
  **License URI:** http://www.gnu.org/licenses/gpl-2.0.html
10
 
17
 
18
  ### Compatibility
19
 
20
+ Requires WordPress 3.8 or higher. The registration form, lost password form, login widget and expired sessions will keep working.
21
 
22
  Compatible with plugins like:
23
 
60
 
61
  ## Changelog
62
 
63
+ ### 1.9
64
+
65
+ * wp-admin will now have a `wp_die()` message instead of a 404 template because this caused problems.
66
+ * Minimum version is now 3.8.
67
+ * Added updates from wp-login.php in 3.8.
68
+
69
  ### 1.8
70
 
71
  * OOP PHP.
readme.txt CHANGED
@@ -2,9 +2,9 @@
2
 
3
  Contributors: avryl
4
  Tags: rename, login, wp-login, wp-login.php, brute force attacks, custom login url
5
- Requires at least: 3.7
6
- Tested up to: 3.7.1
7
- Stable tag: 1.8
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -17,7 +17,7 @@ Please bookmark or remember your login url, accessing wp-login.php or wp-admin w
17
 
18
  = Compatibility =
19
 
20
- Requires WordPress 3.7 or higher. The registration form, lost password form, login widget and expired sessions will keep working.
21
 
22
  Compatible with plugins like:
23
 
@@ -64,6 +64,12 @@ Either go to your MySQL database and look for the value of `rwl_page` in the opt
64
 
65
  == Changelog ==
66
 
 
 
 
 
 
 
67
  = 1.8 =
68
 
69
  * OOP PHP.
2
 
3
  Contributors: avryl
4
  Tags: rename, login, wp-login, wp-login.php, brute force attacks, custom login url
5
+ Requires at least: 3.8
6
+ Tested up to: 3.8
7
+ Stable tag: 1.9
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
17
 
18
  = Compatibility =
19
 
20
+ Requires WordPress 3.8 or higher. The registration form, lost password form, login widget and expired sessions will keep working.
21
 
22
  Compatible with plugins like:
23
 
64
 
65
  == Changelog ==
66
 
67
+ = 1.9 =
68
+
69
+ * wp-admin will now have a `wp_die()` message instead of a 404 template because this caused problems.
70
+ * Minimum version is now 3.8.
71
+ * Added updates from wp-login.php in 3.8.
72
+
73
  = 1.8 =
74
 
75
  * OOP PHP.
rename-wp-login.php CHANGED
@@ -6,7 +6,7 @@ Plugin URI: http://wordpress.org/plugins/rename-wp-login/
6
  Description: Change wp-login.php to whatever you want. It can also prevent a lot of brute force attacks.
7
  Author: avryl
8
  Author URI: http://profiles.wordpress.org/avryl/
9
- Version: 1.8
10
  Text Domain: rename-wp-login
11
  License: GPLv2 or later
12
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -75,7 +75,7 @@ if ( ! class_exists( 'Rename_WP_Login' ) ) {
75
 
76
  global $wp_version;
77
 
78
- if ( version_compare( $wp_version, '3.7', '<' ) ) {
79
 
80
  add_action( 'admin_init', array( $this, 'admin_init_incompatible' ) );
81
  add_action( 'admin_notices', array( $this, 'admin_notices_incompatible' ) );
@@ -216,9 +216,7 @@ if ( ! class_exists( 'Rename_WP_Login' ) ) {
216
 
217
  if ( is_admin() && ! is_user_logged_in() && ! defined( 'DOING_AJAX' ) && ! get_option( 'rwl_admin' ) ) {
218
 
219
- remove_action( 'wp_head', 'mp6_override_toolbar_margin', 11 );
220
-
221
- $this->set_404();
222
 
223
  }
224
 
6
  Description: Change wp-login.php to whatever you want. It can also prevent a lot of brute force attacks.
7
  Author: avryl
8
  Author URI: http://profiles.wordpress.org/avryl/
9
+ Version: 1.9
10
  Text Domain: rename-wp-login
11
  License: GPLv2 or later
12
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
75
 
76
  global $wp_version;
77
 
78
+ if ( version_compare( $wp_version, '3.8', '<' ) ) {
79
 
80
  add_action( 'admin_init', array( $this, 'admin_init_incompatible' ) );
81
  add_action( 'admin_notices', array( $this, 'admin_notices_incompatible' ) );
216
 
217
  if ( is_admin() && ! is_user_logged_in() && ! defined( 'DOING_AJAX' ) && ! get_option( 'rwl_admin' ) ) {
218
 
219
+ wp_die( __( 'You must log in to access the admin area.' ) );
 
 
220
 
221
  }
222
 
rwl-login.php CHANGED
@@ -11,7 +11,7 @@
11
  /** Make sure that the WordPress bootstrap has run before continuing. */
12
  //require( dirname(__FILE__) . '/wp-load.php' );
13
 
14
- global $error, $interim_login, $current_site, $action;
15
 
16
  // Redirect to https login if forced to use SSL
17
  if ( force_ssl_admin() && ! is_ssl() ) {
@@ -33,7 +33,7 @@ if ( force_ssl_admin() && ! is_ssl() ) {
33
  * @param WP_Error $wp_error Optional. WordPress Error Object
34
  */
35
  function login_header($title = 'Log In', $message = '', $wp_error = '') {
36
- global $error, $interim_login, $current_site, $action;
37
 
38
  // Don't index any of these forms
39
  add_action( 'login_head', 'wp_no_robots' );
@@ -59,7 +59,12 @@ function login_header($title = 'Log In', $message = '', $wp_error = '') {
59
  add_action( 'login_head', 'wp_shake_js', 12 );
60
 
61
  ?><!DOCTYPE html>
62
- <html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
 
 
 
 
 
63
  <head>
64
  <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
65
  <title><?php bloginfo('name'); ?> &rsaquo; <?php echo $title; ?></title>
@@ -67,6 +72,7 @@ function login_header($title = 'Log In', $message = '', $wp_error = '') {
67
 
68
  wp_admin_css( 'wp-admin', true );
69
  wp_admin_css( 'colors-fresh', true );
 
70
 
71
  // Remove all stored post data on logging out.
72
  // This could be added by add_action('login_head'...) like wp_shake_js()
@@ -92,7 +98,7 @@ function login_header($title = 'Log In', $message = '', $wp_error = '') {
92
 
93
  if ( is_multisite() ) {
94
  $login_header_url = network_home_url();
95
- $login_header_title = $current_site->site_name;
96
  } else {
97
  $login_header_url = __( 'http://wordpress.org/' );
98
  $login_header_title = __( 'Powered by WordPress' );
@@ -264,7 +270,7 @@ function wp_login_viewport_meta() {
264
  * @return bool|WP_Error True: when finish. WP_Error on error
265
  */
266
  function retrieve_password() {
267
- global $wpdb, $current_site, $wp_hasher;
268
 
269
  $errors = new WP_Error();
270
 
@@ -301,8 +307,8 @@ function retrieve_password() {
301
  /**
302
  * Fires before a new password is retrieved.
303
  *
304
- * @since 1.5.2
305
- * @deprecated 1.5.2 Misspelled. Use 'retrieve_password' hook instead.
306
  *
307
  * @param string $user_login The user login name.
308
  */
@@ -310,7 +316,7 @@ function retrieve_password() {
310
  /**
311
  * Fires before a new password is retrieved.
312
  *
313
- * @since 1.5.2
314
  *
315
  * @param string $user_login The user login name.
316
  */
@@ -510,7 +516,7 @@ case 'retrievepassword' :
510
  /**
511
  * Fires before the lost password form.
512
  *
513
- * @since 1.5.2
514
  */
515
  do_action( 'lost_password' );
516
 
@@ -544,7 +550,7 @@ if ( get_option( 'users_can_register' ) ) :
544
  /**
545
  * Filter the registration URL below the login form.
546
  *
547
- * @since 1.5.2
548
  *
549
  * @param string $registration_url Registration URL.
550
  */
11
  /** Make sure that the WordPress bootstrap has run before continuing. */
12
  //require( dirname(__FILE__) . '/wp-load.php' );
13
 
14
+ global $error, $interim_login, $action;
15
 
16
  // Redirect to https login if forced to use SSL
17
  if ( force_ssl_admin() && ! is_ssl() ) {
33
  * @param WP_Error $wp_error Optional. WordPress Error Object
34
  */
35
  function login_header($title = 'Log In', $message = '', $wp_error = '') {
36
+ global $error, $interim_login, $action;
37
 
38
  // Don't index any of these forms
39
  add_action( 'login_head', 'wp_no_robots' );
59
  add_action( 'login_head', 'wp_shake_js', 12 );
60
 
61
  ?><!DOCTYPE html>
62
+ <!--[if IE 8]>
63
+ <html xmlns="http://www.w3.org/1999/xhtml" class="ie8" <?php language_attributes(); ?>>
64
+ <![endif]-->
65
+ <!--[if !(IE 8) ]><!-->
66
+ <html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
67
+ <!--<![endif]-->
68
  <head>
69
  <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
70
  <title><?php bloginfo('name'); ?> &rsaquo; <?php echo $title; ?></title>
72
 
73
  wp_admin_css( 'wp-admin', true );
74
  wp_admin_css( 'colors-fresh', true );
75
+ wp_admin_css( 'ie', true );
76
 
77
  // Remove all stored post data on logging out.
78
  // This could be added by add_action('login_head'...) like wp_shake_js()
98
 
99
  if ( is_multisite() ) {
100
  $login_header_url = network_home_url();
101
+ $login_header_title = get_current_site()->site_name;
102
  } else {
103
  $login_header_url = __( 'http://wordpress.org/' );
104
  $login_header_title = __( 'Powered by WordPress' );
270
  * @return bool|WP_Error True: when finish. WP_Error on error
271
  */
272
  function retrieve_password() {
273
+ global $wpdb, $wp_hasher;
274
 
275
  $errors = new WP_Error();
276
 
307
  /**
308
  * Fires before a new password is retrieved.
309
  *
310
+ * @since 1.5.0
311
+ * @deprecated 1.5.1 Misspelled. Use 'retrieve_password' hook instead.
312
  *
313
  * @param string $user_login The user login name.
314
  */
316
  /**
317
  * Fires before a new password is retrieved.
318
  *
319
+ * @since 1.5.1
320
  *
321
  * @param string $user_login The user login name.
322
  */
516
  /**
517
  * Fires before the lost password form.
518
  *
519
+ * @since 1.5.1
520
  */
521
  do_action( 'lost_password' );
522
 
550
  /**
551
  * Filter the registration URL below the login form.
552
  *
553
+ * @since 1.5.0
554
  *
555
  * @param string $registration_url Registration URL.
556
  */