The easiest way to hide the backend login address in WordPress

888u

Last update at :2024-05-13,Edit by888u

Hiding the WordPress backend login address is one of the ways to ensure website security. While hiding it, you must delete the website’s links to the login backend.

If you are using the DUX theme, modify the theme file functions.php and insert the following code.

Change mima to the characters you need, and then the login address is: https://***/wp-login.php?mima, Or: https://***/wp-admin?mima

If you do not access according to the above address, you will jump directly to the homepage of the website.

// https://themebetter.com/wordpress-hide-login.html
add_action('login_enqueue_scripts', 'tb_wp_login_protection');
function tb_wp_login_protection(){
if( !isset($_GET['mima']) ){
header( 'Location: ' . home_url() );
exit;
}
}

Recommended site search: website registration domain name query, domain name, host server rental, Korean virtual host, website registration system, Wanwang space, Guangzhou server hosting, icp registration query system, mainland China registration-free space, 6 yuan Alibaba Cloud sharing Virtual host,

The easiest way to hide the backend login address in WordPress

All copyrights belong to 888u unless special state
取消
微信二维码
微信二维码
支付宝二维码