.htaccess errors in WordPress: Rewrite Engine not allowed here

Solution:

The error you’re getting means that the proper override isn’t turned on. Htaccess files “override” settings defined by the config files, and the AllowOverride directive in the config files determine what type of settings can be overridden by htaccess files. As you can see in the Apache mod_rewrite documentation there’s a listing for each directive for Override, that means you need to set that in the config.

Somewhere in your xampp config files you should see a AllowOverride directive. You can either add FileInfo to that list, or you can change it to All:

AllowOverride FileInfo

or

AllowOverride All

This should allow you to use mod_rewrite directives in your htaccess files.


EDIT:

where should i put it? i put allow override everywhere

Take a look at the Apache docs for AllowOverride, you need to put it in a <Directory> container. So something like this:

<Directory "/path/to/your/xampp/wordpress">
    AllowOverride All
</Directory>

You have to make sure that the “/path/to/your/xampp/wordpress” is the absolute physical file path where your htaccess file is, and not the URI path (the path you’d see in, say, the URL). This means your htaccess file would be in /path/to/your/xampp/wordpress/.htaccess.