Go Back   HostGator Peer Support Forums > HostGator Peer Support Forums > Shared Hosting Support

Notices

Reply
 
Thread Tools
  #1  
Old 10-22-2007, 12:15 PM
apinner apinner is offline
Hatchling Croc
 
Join Date: Apr 2007
Posts: 22
Default .htaccess

Hi all,

is it possible to create a .htaccess file that would only allow access to a directory from a specific IP address. For example i wanted to host an intranet that only a single office dsl connection could access?

If anyone knows the answer please let me know..

Thanks in advance
Reply With Quote
  #2  
Old 10-22-2007, 02:54 PM
tparker tparker is offline
Hatchling Croc
 
Join Date: Oct 2007
Posts: 6
Default Re: .htaccess

Something like this should work:

Code:
order deny,allow
deny from all
allow from xxx.xxx.xxx.xxx
Replace xxx.xxx.xxx.xxx with the IP address you want accessing your server. Be sure not to block yourself out when doing this.
Reply With Quote
  #3  
Old 10-22-2007, 03:59 PM
apinner apinner is offline
Hatchling Croc
 
Join Date: Apr 2007
Posts: 22
Default Re: .htaccess

works great, thank you!
Reply With Quote
Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT -5. The time now is 06:52 AM.