In order to do this you need a way to manage users on your website. I recommend using an open source CMS (content managements system). If you are working with .NET, I would use DotNetNuke:
http://www.dotnetnuke.com/
If you are working with the LAMP stack, the I would recommend drupal or joomla:
http://drupal.org/
http://www.joomla.org/
You need to choose one and then start working with it. I use DotNetNuke. There are number of books that you can find on Amazon to get you started with these products. They are open-source (meaning free) and have very large active user communities to help you get started.
Nick