If you are trying to protect your email against email scrapers, just use HTML::email('[email protected]'). This obfuscates email so the actual address does not appear as such in the 'source'.
If you really want to suppress display of full email address, a php function like the following can be used:
//$input is the email address and $show is the number of characters you want displayed.. defaults to 3
function hideEmail($input,$show=3) {
$arr = explode('@', $input);
return substr($arr[0],0,$show).str_repeat('*',strlen($arr[0])-$show).$arr[1];
}
Hope this helps!
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community