Author: drpcken | Posted on: 9/1/2008 8:28:29 AM | Views : 357

I need help with creating a authentication cookie for my site (or advice on a better way to do this).
I have a table in my database for my users (we'll call it tblAuthentication).  It has a username and a password field.  Now I can write the authentication method that will check values in a login form with values in my tblAuthentication table and return a boolean which will let the user in or not, but I'm not sure what to do from there.  What I need help with is creating the cookie and then checking for that cookie on every page of my form.
I'm using a masterpage for 99% of my pages, so can I write the logic there to check for the cookie and load the page or redirect to login?  Is this even the best way to go?  I read a little about the global.asax and from what I understand its events fire off with every page request, not sure if thats right or not though.

I don't want to use the built in FormsAuthentication because I ...

Go to the complete details ...