×PLease Fill this field..! "; exit(); }else{ if(!preg_match($emailValidation,$email)){ echo "
× this $email is not valid..!
"; exit(); } $sql = "SELECT email_id FROM email_info WHERE email = '$email' LIMIT 1" ; $check_query = mysqli_query($con,$sql); $count_email = mysqli_num_rows($check_query); if($count_email > 0){ echo "
× Email Address is already available
"; exit(); }else{ $sql = "INSERT INTO `email_info` (`email_id`, `email`) VALUES (NULL, '$email')"; $run_query = mysqli_query($con,$sql); echo "
× Thanks for subscribing
"; } } } ?>