Here are the steps
Have a user table with a username and password
Give a form for the user to type in his username and password
Get the username and pull up the appropriate record from the DB and compare the passwords (see note)
If the username and password match, set a flag in the session and put the logged in user into the session ($_SESSION['user'] = $user_obj)
Make sure you have a common script in all your pages that check whether $_SESSION['user'] is set and populated. If it's not set, simply point him to the login page.
Note : Make sure you do not store clear passwords. You should store the hash of a password. You can hash it with a salt and use a strong hashing mechanism
Some links to look at
How can I encrypt password data in a database using PHP?
How do you use bcrypt for hashing passwords in PHP?
Also here's a video tutorial on Nettuts about the subject matter : http://net.tutsplus.com/articles/news/how-to-build-a-login-system-for-a-simple-website/