Web Hosting Talk







View Full Version : Limiting access with .htaccess


MicroFX
06-11-2002, 06:52 PM
Hi,

I want to limit access to a directory to only one website/IP but for some reason it still denied that site also. Here is what I have:

<Limit GET PUT POST>
order allow,deny
allow from 63.240.230
allow from e-gold.com
deny from all
</Limit>

Is there something wrong in there? I want the whole class C allowed access so I only put the first 3 numbers of the IP in.

Matt

elsmore1
06-11-2002, 07:17 PM
Try changing the order from "allow,deny" to "deny,allow". Also, unless there is a specific reason that you need to limit only certain types of requests, there is no need vor the <Limit></Limit> block. Just put the other directives in the main section of the .htaccess file.

Originally posted by MicroFX
Hi,

I want to limit access to a directory to only one website/IP but for some reason it still denied that site also. Here is what I have:

<Limit GET PUT POST>
order allow,deny
allow from 63.240.230
allow from e-gold.com
deny from all
</Limit>

Is there something wrong in there? I want the whole class C allowed access so I only put the first 3 numbers of the IP in.

Matt