Simple Login page

Hi all,

     I am stepping into web-development as a hobby point of view. I am using WAMP server & have created the initial page & SQL set-up too. My problem is, I was able to login to a page/redirect to a page though I haven't specified my username & password. I thought of using both client-side Validation & Server-side Validation. Please let me know how to do it. Thank you :\)

So you made your own PHP login script? Do you care to share it for review? The topic is covered a lot, but we can help. Most likely you would want to require_once('login.php') on each each page that needed rights such that it will not continue unless a session is already made, otherwise it displays login form.

Or are you using Apache .htaccess basic auth?

How can I do it with Apache .htaccess?