Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

filter var php function

// filter_var() function  used to filters a variable                                      
//with the help of a specified filter . 
// in php language we use filter_var() To validate data such as email , ipAdress .etc.
// syntax  is filte_var($varName , FILTER_VALIDATE_EMAIL );
//example 
$email ="test@gmail.com";
  if(filter_var($email, FILTER_VALIDATE_EMAIL){
    echo" email adresse is valid   "; 
    
    else{
      
      echo " the email adresse is not valid " ; }

 
PREVIOUS NEXT
Tagged: #filter #var #php #function
ADD COMMENT
Topic
Name
1+4 =