GIDForums  

Go Back   GIDForums > Web Hosting Forums > Apache Web Server Forum
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 01-Nov-2003, 05:15
fraggle two fraggle two is offline
New Member
 
Join Date: Oct 2003
Location: Berlin
Posts: 7
fraggle two is an unknown quantity at this point

bypass htaccess


hi,

is the the possibility to protect my folders with htaccess in that way that no one can browse this folders but when i call the index all files that are requested are shown without the login prompt?

thx
mike
  #2  
Old 01-Nov-2003, 05:34
Allowee's Avatar
Allowee Allowee is offline
Regular Member
 
Join Date: May 2003
Location: The Netherlands
Posts: 339
Allowee has a spectacular aura about
you want the folder to be password protected, and only you can access them.

hmmm..

you can do something like that this way:

<directory /home/user/www/protect>
order deny, allow
deny from all
allow from your.host.name
</directory>

note that this will only work if you have a static hostname.
if you don't change the your.host.name line to
*.a.part.ofyour.hostname

you always need to play a bit with this..
__________________
Pastebin
PHP Documentation Site
Allowee's Blog http://allowee.net
  #3  
Old 01-Nov-2003, 08:29
fraggle two fraggle two is offline
New Member
 
Join Date: Oct 2003
Location: Berlin
Posts: 7
fraggle two is an unknown quantity at this point
hi,

the thing is that i have differen folders (pictures, sounds...)
these folders i want to protect.
in the root lies the index.html and this is not protected.

if i call the root the prompt appears because the index.html needs files from the protected folders.

what i need is that the folders keep protected but the fils that are be used to build the site have to be loaded without the prompt.

i want to prevent that users can browse my folders by bypassing the root but the site should be build normaly.

i hope this is a little bit more helpful.

thx
mike
  #4  
Old 11-Nov-2003, 03:56
Allowee's Avatar
Allowee Allowee is offline
Regular Member
 
Join Date: May 2003
Location: The Netherlands
Posts: 339
Allowee has a spectacular aura about
Sorry for the late response...

maybe this works, haven't tested..

Code:
<Files "index.html"> Allow from All Satisfy Any </Files>

Maybe you can leave the 'satisfy Any' out, but I'm not sure about that.

Place the code in a .htaccess file in the same directory index.html is

Hope this is what you mean (and that it works)

[added]
for you imges you can try
Code:
<Directory "images/"> Allow from All Satisfy Any </Directory>
__________________
Pastebin
PHP Documentation Site
Allowee's Blog http://allowee.net
 

Recent GIDBlogToyota - 2008 July Promotion by Nihal

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 04:37.


vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.