WordPress.org

Forums

.htaccess : Return 404 Not found instead of redirecting (1 post)

  1. halben
    Member
    Posted 1 year ago #

    Is it safe to use this .htaccess to block out wp-login.php & wp-logout.php & wp-admin ??

    RewriteCond %{REQUEST_URI} wp-login.php|wp-admin
    RewriteCond %{REMOTE_ADDR} !^123.456.789.
    RewriteRule . - [R=404,L]

    If anyone knows a better solution, please post. Thanks for looking.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags