splendid Barnaby . superb.
@Barnanby,
Here comes the noob! If not using stackscripts, where would this have to go to take effect? Thanks in advance.
It goes in the nginx configuration file just before the final }
/usr/local/nginx/sites-available/domainname.com
Many many thanks @Barnaby!
One other note. If your wp-admin/ dir is not at the top-level of your htdocs. For example, let’s say it’s in /wp/wp-admin, then you’ll need to ditch the ^s at the start of the string. So for example, the last 4 lines would look like:
if ($remote_addr != "12.34.56.78") {
rewrite /wp-admin/(.*)$ /index.php?q=$1 last;
rewrite /wp-login.php(.*)$ /index.php?q=$1 last;
}
Cheers and thx @Barnaby
PS> Spotted a similar explanation that talked about allowing wp-comments-post.php here: http://www.phrison.com/securing-arbitrary-uris/
Got a Question? Want to Comment?
This site has no comments system. We've got a better system!
Please use the link at the top of the post and goto this topic's forum thread:-
For those posts ported from Guvnr.com (pre-Feb/2010), archive comments remain.
Handy info from these comments is in the process of being ported to the forum and attributed to the original author.
If you think this idea sucks, let me know.
Thank you.