// create a database CREATE DATABASE student USE student // create a table studentdetails CREATE TABLE IF NOT EXISTS studentdetails ( id int(11) NOT NULL AUTO_INCREMENT, name char(50) NOT NULL, email varchar(50) NOT NULL, password varchar(50) NOT NULL, mobile bigint(20) NOT NULL, gender enum('m','f') NOT NULL, hobbies varchar(100) NOT NULL, dob date NOT NULL, address text … Hence this page is accessible to only logged in users. As promised earlier, we do this in the server.php file.Sessions are used to track logged in users and so we include a session_start() at the top of the file.The comments in the code pretty much explain everything, but I'll highlight a few things here.The if statement determines if the reg_user button on the registration form is clicked. So open the server.php file and add this code at the end of the file:Again all this does is check if the user has filled the form correctly, verifies that their credentials match a record from the database and logs them in if it does. You can learn more about this in our PHP tutorial. registration.php When you login into a website or into your mail box, you are interacting with a form. We will use simple tags and also we will use table tag to design the Sign-Up.html webpage. I will also show you how you can make some pages accessible only to logged-in users. If you'd like to make any page accessible only to logged in users, all you have to do is place this if statement at the top of the file.The second if statement checks if the user has clicked the logout button. Much of the websites have a registration form for your users to sign up and thus may benefit from some kind of privilege within the site. Remember, in our form, the submit button has a name attribute set to reg_user and that is what we are referencing in the if statement.All the data is received from the form and checked to make sure that the user correctly filled the form. We will come to that soon.As you can see in the head section, we are linking to a style.css file. How To Create a Register Form Step 1) Add HTML: Use a