php forum
php mysql forum
php mysql smarty
 
Topic Options
#104683 - 02/22/03 04:52 PM .htaccess to protect only specific files
usr bin geek Offline
Moderator / Kingpin

Registered: 02/11/01
Posts: 817
Loc: Burlington, VT
I have a directory where every file in the directory but three should be protected by password. Is there a way to do this using .htaccess on Apache? What would the correct code be for the .htaccess file?

BTW, all the files in the directory have the same extension (.php so a *.php won't work.)

Someone gave me this code but it causes an error if anything is loaded from that directory:
[code][/code]
_________________________
Steve
ImetSteve.com

Sorry, I wont answer support questions by email, PM, or IM.

Top
#104684 - 02/22/03 08:30 PM Re: .htaccess to protect only specific files
Charles Capps Offline
Admin Emeritus

Registered: 01/09/00
Posts: 5438
Loc: Lynnwood, WA
Either don't include an AuthGroupFile directive, or make it a real groups file.
_________________________
UBB.classic: Love it or hate it, it was mine.

Top
#104685 - 02/24/03 11:08 AM Re: .htaccess to protect only specific files
joking-down Offline
deutscher moderator / v5 specialist

Registered: 12/24/00
Posts: 712
Loc: Germany
try this:

[code][/code]it works on my Apache 1.3.23 (Win32)...
_________________________
UBB-Admin ( kids-hotline.de )


join Team UBBDev

I have [img]http://www.ubbdev.com/ud/?s=1&u=joking-down[/img] Points.

Top
#104686 - 02/24/03 11:19 AM Re: .htaccess to protect only specific files
usr bin geek Offline
Moderator / Kingpin

Registered: 02/11/01
Posts: 817
Loc: Burlington, VT
That works Joking-down, thanks!

For some strange reason this host requires that dev/null AuthGroupFile directive
_________________________
Steve
ImetSteve.com

Sorry, I wont answer support questions by email, PM, or IM.

Top



Latest Posts
[7.2.1] - Naked shoutbox
by bellaonline
05/05/12 05:00 PM
[7.x] Stop Forum Spam Integration v0.4
by bellaonline
05/05/12 03:53 PM
Shout Box

(Views)Popular Topics
Known public proxy servers 1689885
Integrated Index Page (IIP) 5.3.1 555705
Finished-[6.5.2] Games Arcade Deluxe v1.9 501236
Integrated Index Page (IIP) 5.1.1 415112
TLD Bv2.1 Released - Threads Links Directory 396822
[6.0x] Who's Online 4.0.0 [Finished] 389412
Finished-[6.5.1] Integrated Index Page (IIP) 6.5 330423
Q & A 298663
Slash UBB 266936
[6.3.x] [beta] Hit Hack 2.0 227970
Forum Stats
13621 Members
59 Forums
37191 Topics
295716 Posts

Max Online: 686 @ 06/28/07 07:04 AM

 

 

 
fusionbb message board php hacks