Allow only selected password!

Results 1 to 2 of 2

Thread: Allow only selected password!

  1. #1
    Join Date
    Dec 1969

    Default Allow only selected password!

    How can I allow only selected users&#039; logins to my page? For Example: <BR>My database Login Table has 100 names, I only want 5 of those people with permission to my site, but I want to use the Login Table. So how can I write a statement to point to only those 5 users to allow to my page?<BR><BR>Thank you in advance Gentlemen!

  2. #2
    Join Date
    Dec 1969

    Default Add a field to the database...

    Add a simple integer or yes/no or bit field to the table.<BR><BR>Let&#039;s say it&#039;s an integer and the field is named "SpecialPermissions".<BR><BR>And let&#039;s say that the higher the number in that field, the more permissions the user has.<BR><BR>If you set the default value of the field to zero, then when you add the field all users will get a zero, meaning "minimum permissions".<BR><BR>Then you change the permission number for those five users, say to 100 or 10 or any number you want.<BR><BR>And now, in your SQL, you do:<BR><BR>SQL = "SELECT * FROM table WHERE SpecialPermissions &#062;= 100 AND " _<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; & " UserName=&#039;" & Request("user") & "&#039;" _<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; & " AND UserPassword=&#039;" & Request("userPassword") & "&#039;"<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts