修改WordPress后台登录地址

//保护后台登录
add_action('login_enqueue_scripts','login_protection');  
function login_protection(){  
    if($_GET['site'] != 'anttoweb')header('Location: '.home_url());  
}

这样一来,后台登录的唯一地址就是 http://yoursite/wp-login.php?site=anttoweb

368 total views, 4 views today

Revisions

There are no revisions for this post.

Comments are closed.