2

I would like to ask for help. I have .htaccess like this:

Options +Indexes
RewriteEngine On
RewriteBase /

RewriteCond %{HTTP_HOST} !example.com$ [NC]
RewriteRule ^(.*)$ http://example.com/$1 [L,R=301]

RewriteCond %{SCRIPT_FILENAME} !-d
RewriteCond %{SCRIPT_FILENAME} !-f
RewriteRule ^advert/([^/]+)/?$ advert.php?id=$1 [L]

RewriteCond %{SCRIPT_FILENAME} !-d
RewriteCond %{SCRIPT_FILENAME} !-f
RewriteRule ^adverts/([^/]+)/?$ adverts.php?kat=$1 [L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^(.*)$ $1.php [NC,L]

And the problem is that it's causing 503 errors.

In the error log I see:

URL like this: example.com/advert/test generates this error:

[Mon Dec 14 10:01:24 2015] [error] [client 157.55.39.109] client denied by server configuration: /data/web/virtuals/56654/virtual/www/advert

and later this one:

[Mon Dec 14 10:06:25 2015] [error] [client 2a03:2880:1010:6fe8:face:b00c:0:8000] Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace.

Where am I wrong? Thanks everyone.

Pavel Straka
  • 427
  • 7
  • 19

0 Answers0