htaccess in wrong place
-
Hello everybody –
I wonder if anybody could point me in the right direction please.
Just set my first self-hosted WP site up. Everything is working great.
However, just installed and run WP-Security which tells me “The file .htaccess does not exist in wp-admin/. “
On checking I find yes, I have for some reason put my .htaccess file in the root of my website, not inside the ‘wordpress’ directory. My file structure on the hosted website is: root, then a ‘WordPress’ directory, and everything to do with WP is inside this directrory. My .htaccess is outside the ‘WordPress’ folder.
I realise now this is wrong. However, when I move the .htacess file to my wordpress/wp-admin folder, I get various 404 errors (pages that were coming up fine before the .htaccess move now can’t appear). If I move the .htaccess file back to the root, everything on the site is fine again.
This is a little beyond my very limited knowledge of htaccess, unix, etc. so I wonder if anybody could point me a step-by-step instruction sheet for moving my .htaccess to eliminate this security risk spotted by WP-Security plugin.
For info, my htaccess file looks like this (I have no idea what it means, it was created for me when I set my permalinks up and the screen told me to create one – at the time I did this I had no idea it needed to go into the wp-admin folder):-
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>That’s it. Thanks in advance
The topic ‘htaccess in wrong place’ is closed to new replies.