.htaccess : Location not allowed here

Pedro Rolo picture Pedro Rolo · Jul 12, 2011 · Viewed 20.5k times · Source

I am getting a "Location not allowed here" error with this .htaccess.

Does anyone have any idea on how I should fix this?

<Files 'login'>
    AuthName NTLM
    AuthType NTLM
    NTLMAuth on
    NTLMAuthoritative on
    NTLMServer <censored>
    NTLMBackup <censored>
    NTLMLockfile <censored>
    require valid-user
    Satisfy all
</Files>
<Location /alarms/[0-9]+/acknowlege>
    Order deny,allow
    Deny from all
    Allow from localhost
</Location>

Answer

Sean Adkinson picture Sean Adkinson · Jul 12, 2011

Location isn't valid in .htaccess

See:

Notice how Files says that you can have it in .htaccess, but Location doesn't... You'll need to add your Location to either the server config or a virtual host.