Tech Study

Write a simple PHP program to check that email id is valid or not

Introduction

PHP is a server scripting language, and It is a powerful tool for making interactive and dynamic Web-pages. I have used WampServer 2.2 for following excercise..

<?php
// Passing valid/invalid email
$email = "techstudy.org@gmail.com";
if (filter_var($email, FILTER_VALIDATE_EMAIL)) 
{     
 
     echo '"' . $email . '" is valid Email ID'."\n";
}
else 
{     
     echo '"' . $email . '" is invalid Email ID'."\n";
}
?>

Result

Write a simple PHP program to check that email id is valid or not
Write a simple PHP program to check that email id is valid or not

TaggedWrite a simple PHP program to check that email id is valid or not

Python datetime (With Examples)

Python datetime Python has an inbuilt module known as datetime module to basically deal with the operations on dates and …

Read more

Python Examples

Introduction: Python Examples are the basic programming concepts of python like python syntax,python data types,,python operators,python if else,python comments etc.. …

Read more