To HTACCESS protect pages for members only...
Install mod_auth_mysql on apache.
then for example in httpd.conf
<DIRECTORY /home/testdir>
AuthType Basic
AuthUserfile /dev/null
AuthName "Forum Member Access Only"
AuthType Basic
AuthGroupFile /dev/null
AuthMySQLHost localhost
AuthMySQLCryptedPasswords Off
AuthMySQLUser <user>
AuthMySQLPassword <pw>
AuthMySQLDB <forums dbase name>
AuthMySQLUserTable user
AuthMySQLNameField username
AuthMySQLPasswordField password
<Limit GET POST>
require valid-user
</limit>
</DIRECTORY>
just change user/pw to user/pw you use to access dbase and dbase name to whatever ya dbase is called and bobs ya uncle.
Or....
<DIRECTORY /home/testdir>
AuthType Basic
AuthUserfile /dev/null
AuthName "Member Access Only"
AuthType Basic
AuthGroupFile /dev/null
AuthMySQLHost localhost
AuthMySQLCryptedPasswords Off
AuthMySQLUser <user>
AuthMySQLPassword <pw>
AuthMySQLDB <forums dbase name>
AuthMySQLUserTable user
AuthMySQLNameField username
AuthMySQLPasswordField password
AuthMySQLGroupField usergroupid
<Limit GET POST>
require group 6 7
</limit>
</DIRECTORY>
The above example restricts to forum members who are 'admins & mods' a list of our group ids are..
# GROUP ID's
# 1 Unregistered / Not Logged In
# 2 Registered
# 3 Users Awaiting Email Confirmation
# 4 (COPPA) Users Awaiting Moderation
# 5 JNR Admin
# 6 Administrator
# 7 Moderators
# 8 Banned
# 9 Moderated
# 10 Gold Member
# 11 Platinum Member
You can see we have a few of ours added at the end, lol
Good luck