Starting Vocational Training From 1-May-2024 Get Detail

How to create login form in php

By : Admin     |     Website,Vocational Training,Programing Knowledge,Interview Question     |     13th April 2019

In this article we will learn how to create login form in php before starting if you dont know about PHP & Mysql Database. So first We Learn Little Bit of PHP and Mysql Database.


PHP is a server scripting language, and a powerful tool for making dynamic and interactive Web pages.

Mysql Database

  • MySQL is a database system used on the web
  • MySQL is a database system that runs on a server
  • MySQL is ideal for both small and large applications
  • MySQL is very fast, reliable, and easy to use
  • MySQL uses standard SQL
  • MySQL compiles on a number of platforms
  • MySQL is free to download and use
  • MySQL is developed, distributed, and supported by Oracle Corporation

Step 1

Create HTML Form : in step 1 first we will create two text box. first is name with attribute txtname and second is txtpass and one submit button that name is submit



after clicking on submit button page will call action="login_do.php" attribute of form

Step 2

Add Css

Step 3

create login_do.php

in this page we will receive txtname,txtpass in variable $txtname,$txtpass


step 4

database connectivity

for database connection here we are using mysql database 

here login is name of database

step 5

table createing

first create database using mysql which name is login and then create table which name is login_form