Version Description
- Revert to code in tag 1.5.3
Download this release
Release Info
Developer | NicolasKulka |
Plugin | WPS Hide Login |
Version | 1.5.4.2 |
Comparing to | |
See all releases |
Code changes from version 1.5.4.1 to 1.5.4.2
- classes/plugin.php +9 -30
- readme.txt +4 -1
- wps-hide-login.php +2 -2
classes/plugin.php
CHANGED
@@ -140,18 +140,13 @@ class Plugin {
|
|
140 |
|
141 |
public function new_login_url( $scheme = null ) {
|
142 |
|
143 |
-
$url = home_url( '/', $scheme );
|
144 |
-
if ( function_exists('icl_object_id') ) {
|
145 |
-
$url = site_url( '/', $scheme );
|
146 |
-
}
|
147 |
-
|
148 |
if ( get_option( 'permalink_structure' ) ) {
|
149 |
|
150 |
-
return $this->user_trailingslashit( $
|
151 |
|
152 |
} else {
|
153 |
|
154 |
-
return $
|
155 |
|
156 |
}
|
157 |
|
@@ -159,18 +154,13 @@ class Plugin {
|
|
159 |
|
160 |
public function new_redirect_url( $scheme = null ) {
|
161 |
|
162 |
-
$url = home_url( '/', $scheme );
|
163 |
-
if ( function_exists('icl_object_id') ) {
|
164 |
-
$url = site_url( '/', $scheme );
|
165 |
-
}
|
166 |
-
|
167 |
if ( get_option( 'permalink_structure' ) ) {
|
168 |
|
169 |
-
return $this->user_trailingslashit( $
|
170 |
|
171 |
} else {
|
172 |
|
173 |
-
return $
|
174 |
|
175 |
}
|
176 |
|
@@ -352,18 +342,13 @@ class Plugin {
|
|
352 |
|
353 |
public function whl_page_input() {
|
354 |
|
355 |
-
$url = home_url();
|
356 |
-
if ( function_exists('icl_object_id') ) {
|
357 |
-
$url = site_url();
|
358 |
-
}
|
359 |
-
|
360 |
if ( get_option( 'permalink_structure' ) ) {
|
361 |
|
362 |
-
echo '<code>' . trailingslashit(
|
363 |
|
364 |
} else {
|
365 |
|
366 |
-
echo '<code>' . trailingslashit(
|
367 |
|
368 |
}
|
369 |
|
@@ -372,19 +357,13 @@ class Plugin {
|
|
372 |
}
|
373 |
|
374 |
public function whl_redirect_admin_input() {
|
375 |
-
|
376 |
-
$url = home_url();
|
377 |
-
if ( function_exists('icl_object_id') ) {
|
378 |
-
$url = site_url();
|
379 |
-
}
|
380 |
-
|
381 |
if ( get_option( 'permalink_structure' ) ) {
|
382 |
|
383 |
-
echo '<code>' . trailingslashit(
|
384 |
|
385 |
} else {
|
386 |
|
387 |
-
echo '<code>' . trailingslashit(
|
388 |
|
389 |
}
|
390 |
|
@@ -466,7 +445,7 @@ class Plugin {
|
|
466 |
|
467 |
$pagenow = 'index.php';
|
468 |
|
469 |
-
} elseif ( ( isset( $request['path'] ) && untrailingslashit( $request['path'] ) ===
|
470 |
|| ( ! get_option( 'permalink_structure' )
|
471 |
&& isset( $_GET[ $this->new_login_slug() ] )
|
472 |
&& empty( $_GET[ $this->new_login_slug() ] ) ) ) {
|
140 |
|
141 |
public function new_login_url( $scheme = null ) {
|
142 |
|
|
|
|
|
|
|
|
|
|
|
143 |
if ( get_option( 'permalink_structure' ) ) {
|
144 |
|
145 |
+
return $this->user_trailingslashit( home_url( '/', $scheme ) . $this->new_login_slug() );
|
146 |
|
147 |
} else {
|
148 |
|
149 |
+
return home_url( '/', $scheme ) . '?' . $this->new_login_slug();
|
150 |
|
151 |
}
|
152 |
|
154 |
|
155 |
public function new_redirect_url( $scheme = null ) {
|
156 |
|
|
|
|
|
|
|
|
|
|
|
157 |
if ( get_option( 'permalink_structure' ) ) {
|
158 |
|
159 |
+
return $this->user_trailingslashit( home_url( '/', $scheme ) . $this->new_redirect_slug() );
|
160 |
|
161 |
} else {
|
162 |
|
163 |
+
return home_url( '/', $scheme ) . '?' . $this->new_redirect_slug();
|
164 |
|
165 |
}
|
166 |
|
342 |
|
343 |
public function whl_page_input() {
|
344 |
|
|
|
|
|
|
|
|
|
|
|
345 |
if ( get_option( 'permalink_structure' ) ) {
|
346 |
|
347 |
+
echo '<code>' . trailingslashit( home_url() ) . '</code> <input id="whl_page" type="text" name="whl_page" value="' . $this->new_login_slug() . '">' . ( $this->use_trailing_slashes() ? ' <code>/</code>' : '' );
|
348 |
|
349 |
} else {
|
350 |
|
351 |
+
echo '<code>' . trailingslashit( home_url() ) . '?</code> <input id="whl_page" type="text" name="whl_page" value="' . $this->new_login_slug() . '">';
|
352 |
|
353 |
}
|
354 |
|
357 |
}
|
358 |
|
359 |
public function whl_redirect_admin_input() {
|
|
|
|
|
|
|
|
|
|
|
|
|
360 |
if ( get_option( 'permalink_structure' ) ) {
|
361 |
|
362 |
+
echo '<code>' . trailingslashit( home_url() ) . '</code> <input id="whl_redirect_admin" type="text" name="whl_redirect_admin" value="' . $this->new_redirect_slug() . '">' . ( $this->use_trailing_slashes() ? ' <code>/</code>' : '' );
|
363 |
|
364 |
} else {
|
365 |
|
366 |
+
echo '<code>' . trailingslashit( home_url() ) . '?</code> <input id="whl_redirect_admin" type="text" name="whl_redirect_admin" value="' . $this->new_redirect_slug() . '">';
|
367 |
|
368 |
}
|
369 |
|
445 |
|
446 |
$pagenow = 'index.php';
|
447 |
|
448 |
+
} elseif ( ( isset( $request['path'] ) && untrailingslashit( $request['path'] ) === home_url( $this->new_login_slug(), 'relative' ) )
|
449 |
|| ( ! get_option( 'permalink_structure' )
|
450 |
&& isset( $_GET[ $this->new_login_slug() ] )
|
451 |
&& empty( $_GET[ $this->new_login_slug() ] ) ) ) {
|
readme.txt
CHANGED
@@ -6,7 +6,7 @@ Tags: rename, login, wp-login, wp-login.php, custom login url, jetpack, wpserveu
|
|
6 |
Requires at least: 4.1
|
7 |
Tested up to: 5.2
|
8 |
Requires PHP: 7.0
|
9 |
-
Stable tag: 1.5.4.
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
12 |
|
@@ -146,6 +146,9 @@ La première étape consiste à vérifier votre fichier .htaccess et à le compa
|
|
146 |
|
147 |
== Changelog ==
|
148 |
|
|
|
|
|
|
|
149 |
= 1.5.4.1 =
|
150 |
* Fix : home_url / site_url
|
151 |
|
6 |
Requires at least: 4.1
|
7 |
Tested up to: 5.2
|
8 |
Requires PHP: 7.0
|
9 |
+
Stable tag: 1.5.4.2
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
12 |
|
146 |
|
147 |
== Changelog ==
|
148 |
|
149 |
+
= 1.5.4.2 =
|
150 |
+
* Revert to code in tag 1.5.3
|
151 |
+
|
152 |
= 1.5.4.1 =
|
153 |
* Fix : home_url / site_url
|
154 |
|
wps-hide-login.php
CHANGED
@@ -5,7 +5,7 @@ Description: Protect your website by changing the login URL and preventing acces
|
|
5 |
Donate link: https://www.paypal.me/donateWPServeur
|
6 |
Author: WPServeur, NicolasKulka, tabrisrp
|
7 |
Author URI: https://wpserveur.net
|
8 |
-
Version: 1.5.4.
|
9 |
Requires at least: 4.1
|
10 |
Tested up to: 5.2
|
11 |
Requires PHP: 7.0
|
@@ -21,7 +21,7 @@ if ( ! defined( 'ABSPATH' ) ) {
|
|
21 |
}
|
22 |
|
23 |
// Plugin constants
|
24 |
-
define( 'WPS_HIDE_LOGIN_VERSION', '1.5.4.
|
25 |
define( 'WPS_HIDE_LOGIN_FOLDER', 'wps-hide-login' );
|
26 |
|
27 |
define( 'WPS_HIDE_LOGIN_URL', plugin_dir_url( __FILE__ ) );
|
5 |
Donate link: https://www.paypal.me/donateWPServeur
|
6 |
Author: WPServeur, NicolasKulka, tabrisrp
|
7 |
Author URI: https://wpserveur.net
|
8 |
+
Version: 1.5.4.2
|
9 |
Requires at least: 4.1
|
10 |
Tested up to: 5.2
|
11 |
Requires PHP: 7.0
|
21 |
}
|
22 |
|
23 |
// Plugin constants
|
24 |
+
define( 'WPS_HIDE_LOGIN_VERSION', '1.5.4.2' );
|
25 |
define( 'WPS_HIDE_LOGIN_FOLDER', 'wps-hide-login' );
|
26 |
|
27 |
define( 'WPS_HIDE_LOGIN_URL', plugin_dir_url( __FILE__ ) );
|