Click here to Skip to main content
15,667,577 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
See more:
sir ,
I want to use Role based Authorization and Authentication with using sql server as database through coding, but without using Website Administration Tools/in build login controls (API). Is their any way .

Thanking You
Updated 13-Dec-11 1:36am

yes we can do
--Add one more column to the SQL server database as "role"
--In database you manually enter a field
User_name="Super user"
Address="xyz Company"
--Now get the role value as session
--compare the session
--if the session is "Super" navigate to admin page(this navigation is only for super user)
--In the admin page you select the user and select the role and update.
--Every time when a user logged in get "role" in session and give authentication as per "role"(this you can do by if, else-if statements).

Initially when a new user register's then the "role" must be "new".
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900