Jump to content

User Management Help


anshuverma1989

Recommended Posts

Hey guys..

 

This site is great ... hehe .. learnt alot .. but i am stuck with one script i am working on...

 

Now the thing is in my script.. there can  be only three type of membership .. Admin, Sub-Admin and Users.

 

and admins can make sub-admins.. and sub-admins can make users.

 

and no one can register it self.. only the higher authority can create there account.. Delete there account.. or change there password..

 

and yeah like if there are suppose 2 sub-admins .. A and B and there are two users C and D which are made by A and B respectively...

 

Means .. A made C and B made D.. so now B cannot control C .. not A cannot control D..

 

is it possible?? if yes.. how??

 

i am confused..

 

Link to comment
https://forums.phpfreaks.com/topic/140313-user-management-help/
Share on other sites

Yes,

 

First of all that is possible. Second, no one is going to write a script for you. If you have a question someone is more than willing to help you but you have to show that you have made an attempt(show some code). In your situation I would like to tell you to look into database normalization. Basically what that is, is making different tables with linked keys. So your database could look something like this

 

table1  memberships

field1 id

field2 type (admin, sub_admin, users)

 

table2 users

field1 id

field2 username

field3 password

field4 membership id

field5 register id

 

Basically when you create the register section you would set their membership id as the type id from the first table in the second table so that they are linked. The register id would be the id from the users table from the person who registered them.

 

This project is a little more in depth than you may be ready for. I would suggest that you learn some php basics before attempting a project like this.

Link to comment
https://forums.phpfreaks.com/topic/140313-user-management-help/#findComment-734251
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.