N
N
nonbody2017-04-20 21:01:11
Apache HTTP Server
nonbody, 2017-04-20 21:01:11

Deny from in htaccess how to write correctly?

Is it necessary to specify "order allow" etc.?
Or is it enough to enter the line "Deny from %IP%"?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Valery, 2017-04-20
@supervaleha

The simplest example would look something like this: (offhand)

Order allow,deny
Deny from 0.0.0.1
Deny from 0.0.0.2
Allow from all

Better yet, specify a list of allowed:
Order deny,allow
deny from all
Allow from 0.0.0.1
Allow from 0.0.0.2

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question