From 936722880068c79dd488016dc0cc4d99af41f77b Mon Sep 17 00:00:00 2001 From: Andy Miller Date: Sun, 24 Aug 2014 11:33:29 -0600 Subject: [PATCH] Added an entry about potential need of RewriteBase and tweaked the index.php rewrite rule --- .htaccess | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.htaccess b/.htaccess index e2a441c7d..1ecd2b921 100755 --- a/.htaccess +++ b/.htaccess @@ -3,10 +3,17 @@ Options -Multiviews RewriteEngine On +# If you are getting 404 errors on subpages, you may have to uncomment the RewriteBase entry +# You should change the '/' to your appropriate subfolder. For example if you have +# your Grav install at the root of your site '/' should work, else it might be something +# along the lines of: RewriteBase / + +#RewriteBase / + # access site RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d -RewriteRule . index.php [L] +RewriteRule ^(.*)$ index.php [QSA,L] # block various user files from being accessed directly RewriteRule ^user/accounts/(.*)$ error [R=301,L]