PHP jQuery AJAX Live check email Availability

PHP jQuery AJAX Live check email Availability

Today, We want to share with you PHP jQuery AJAX Live check email Availability.
In this post we will show you Live check email Availability Check using PHP and jQuery AJAX, hear for Email live availability check using jquery and Ajax in PHP we will give you demo and example for implement.
In this post, we will learn about Live Username Availability Check using PHP and jQuery AJAX with an example.

Live check domainname-username-email checker for registration search domain name cehck has become useful part of live check registration or availability or not system.
This PHP script therefor able to also be used for any other purpose, such as checking domain name, email address or other any things
just we will see a simple javascript with PHP script to implement domain name or username live checking feature using AJAX technologies, jQuery technologies and MySQL database.
This is a most common and best popular feature available in the most of the websites or blogs available online.

Checking domain name and UserName and Email Address of the user on add form or SignUp form is good way to prevent duplicate content on mysql-database and several all other many problems solution.

create a database -mysql

first of all create Database Name : domain_hostexamples
second thing run this script in sql : user.sql

[code]
CREATE TABLE IF NOT EXISTS `domain_mst` (
`domainId` int(8) NOT NULL AUTO_INCREMENT,
`domainName` varchar(55) NOT NULL,
`password` varchar(55) NOT NULL,
`d_firstName` varchar(55) NOT NULL,
`d_lastName` varchar(55) NOT NULL,
PRIMARY KEY (`domainId`)
)

INSERT INTO `domain_mst` (`domainId`, `domainName`, `password`, `d_firstName`, `d_lastName`) VALUES
(24, ‘gtu’, ”, ‘gtu’, ‘com’),
(26, ‘w3free’, ”, ‘w3free’, ‘com’),
(27, ‘w3schools’, ”, ‘w3schools’, ‘com’),
(28, ‘pakainfo’, ”, ‘pakainfo’, ‘com’);

[/code]

File Name : index.php






File Name : do_check_availability_page.php

require_once("dbcontroller.php"); //include custome file
$db_handle = new DBController(); //object created

//check condition using php

if(!empty($_POST["domainName"])) {
  $query_result = mysql_query("SELECT count(*) FROM domain_mst WHERE domainName='" . $_POST["domainName"] . "'");
  $fetch_row = mysql_fetch_row($query_result);
  $total_user_count = $fetch_row[0];
  if($total_user_count>0) {
      echo " Domain Name Not Available.";
  }else{
      echo " Domain Name Available.";
  }
}

Leave a Comment