Convert Public Email Address to Text Script

Convert Public Email Address to Text Script is used to if you give to email mail address at text box the output returns will be displayed text format.

Demo :



Email :   

Example :

sachin@gmail.com

Just type sachin@gmail.com at text box and then click convert button finally output will be displayed sachin at gmail dot com.

Following code is Convert Public Email Address to Text Script if you need to use it.


<?php
function protectEmail($email)
{
  $search = array(".", "-", "_", "@");
  $replace = array(" dot ", " dash ", " underscore ", " at ");
  return str_replace($search, $replace, $email);
}
print protectEmail('sachin@gmail.com');
?>

In the above function $search variable is assign to special character for this use email id and $replace variable is use to alternative replace letter for this replace function.

Free Download Script :

If you need to Convert Public Email Address to Text Script click and download from following link.

Download




Content