.htaccess does not work

I did a new installation of xampp, after installing the folder containing the following htaccessfile, it does not appear in my browser.

SetEnv APPLICATION_ENV development

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]

it gives 500 errors and the server is overloaded

This happens when I try to execute a shared folder in my zend application.

Please invite me to make any changes to my xampp to properly execute my file .htaccess.

Thanks in advance

+3
source share
1 answer

1) Make sure you include mod_rewriteApache in the configuration file.

2) Add a line AllowOverride Allto the directory configuration in the Apache configuration file.

In addition, if you do not have many rewrites, I recommend the following according to your current rules.

SetEnv APPLICATION_ENV development

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-s
RewriteCond %{REQUEST_FILENAME} !-l
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^.*$ index.php [NC,L]
+5
source

All Articles