If anyone else has any further ideas, please let me know - thanks.

Thanks Jim for the nuke idea, I've downloaded it & am looking through
it... very exhaustive though...

Thanks Jeff on your thoughts.
I've been thinking along very similar lines to what you suggested...

- I have a contents table & plan to add a column "authlevel" (Authority
Level), so that each page will have a defined minimum access.
- I was thinking of creating a "members" table with "username",
"password", "authaccess".
  I liked the idea of leaving room for further growth, and the 'x <= y'
control rather than the 'if x = y' or case equivalent.
- Establish an SSH session between the browser & server for the
session/cookie establishment when the username & password are submitted
(a lot of reading may be needed for this one I think...).
- use either sessions to control the access, or cookies (from what I've
read, people seem to favour sessions, I will have to do some reading
before I make my choice).

It is good to know there are others out there that are thinking in the
same mannor for this... Let me know how you progress.


-----Original Message-----
From: Baumgartner Jeffrey [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, 23 January 2003 9:05 PM
Subject: RE: [PHP-DB] Members area

I'm working on a similar project - I'm also a newbie - here's my
approach - which is fairly simple really.

Create a database of all members that includes columns for "login",
"name" and "paymentStatus" as well as any other info you need for your
database. paymentStatus would be an integer with values of 2 and 5
initially (this allows room for the creation of other levels in the
future) in which 2 is for paid members and 5 is for free members.

Once members log-in, their paid status is saved as a session variable:

All member-area pages will start with session_start(); at the beginning
and a check of the value of $paymentStatus. If it is null, they are sent
to the log-in page. If the page is for members only, then the value of
$paymentStatus must be <=2. If it is for any member, then $paymentStatus
will have to be <=5 (this all gives room for different levels of
membership in the future, you see).

Likewise content, which is stored on tables, includes a $paid variable
which indicates who is able to view it. This way, you can deliver
dynamic content, links and other information according to the
$paymentStatus value of each visiting member. In my case, I will have
index pages with links to content pages. All links will be visible, but
links for paid members will be clearly indicated. The purpose of this is
to show freeloaders what they are missing!

I hope this is clear. More experienced members of this list may well
find flaws with my method.

Good luck,

Jeffrey Baumgartner

eBusiness Consultant - ITP Europe
+32 2 721 51 00

> -----Original Message-----
> From: Gavin Amm [SMTP:[EMAIL PROTECTED]]
> Sent: Thursday, January 23, 2003 2:03 AM
> Subject:      [PHP-DB] Members area
> Hi All,
> I'm about to start development on a members area for a site. The 
> members area will have 2 levels - Paid & Free, with the Paid members 
> having access to more pages.
> I have not created a members area before & am after any advice or 
> links I can get... I think a lot of reading is in order...
> Particularly:
> - DB structure & fields (I'll be using MySQL if that's relevant)
> - Sessions (I've seen quite a few threads covering sessions over the 
> last couple of months, so should have some links in my 'inbox' 
> somewhere... But the more the merrier...)
> - Any PHP suggestions/advice/links
> - Anything else you can think is relevant...
> Thanks, this will be a big help.
> Cheers,
> Gav
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php

PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to