PDA

View Full Version : check for registration on a directory


Jakeman
11-27-2001, 07:22 PM
what i want: check for registration (login cookie) when entering the "files" directory on my server. nothing special at all... simply an "if registered then load directory else show default no access page".

i assume this involves a .htaccess file...

i already do this with my jpilot chat integration in the php script i made for it. but .htaccess isn't php so i'm not sure what to do here.

-dloh-hammer
11-27-2001, 08:42 PM
hmm i need the same but some changes i need:

i need to protect an directory on my webserver like this

/memberarea/index.php

the login code must check the usergroup like gr. 1 5 8 12 may enter all other gets the error NOACCES msg

is it possible to use this code and what changes to to:

require("./global.php");

if ($bbuserinfo[userid]==0) {
show_nopermission();
}

@Jakeman create an index.php and put this code in it all regged members are able to viev the page others get logincode

Jakeman
11-27-2001, 09:17 PM
i'm doing this for a directory with no index, not for one file in the vb root. i already know how to check reg and user groups with php.

-dloh-hammer
11-28-2001, 11:49 AM
ok my mistake

Jakeman
11-30-2001, 05:45 AM
i bump u!

... in teh face :p

Jakeman
12-07-2001, 07:16 AM
one more time...

tube is trying to help me with this on vb.com but we are both kind of stumped. keep in mind that this would have to be .htaccess since i want to prevent direct linking or access of any kind for those that aren't logged in. i know how to do this with php but not with .htaccess . anyone?