Login form that redirects user to specific page

Hey there campers, it’s been a while…
This is what I would like to do:

  1. Login form on home page (user name & password)
    once a user logs in they are redirected to a specific URL dependent on the specific user.
    EX. User1 : redirects to www.user1page.com
    User2 : redirects to www.user2page.com
    and so forth.
    I figure this will require 3 elements
    html form
    php handler
    sql database with at least 3 fields (user name, password, redirect url)

My question is if anybody has a link to a good tutorial / code snippets showing how to do this.

Thanks in advance

Nothing so far starting the search and figured this was a good place to start.
Looking into stack overflow and such but thought that someone here might have done something like this already.