Forum Moderators: coopster
I wrote
<?php//initialize spam-off function (embed it inna page) - JavaScript
function mailto($address,$text='',$subject=''){
$address="user@example.com";
#divide user from host (cut on @)
$data = explode("@","$address");
#a little extra make-up :)
$hostitj = ereg_replace("\.", ' <u>[dot]</u> ', $data[1]);
#if no text present, display address, just a little formatted ;-)
if ("$text" == "") { $text = $data[0] . ' <u>[at]</u> ' . $hostitj; }
#write link
echo "<a href=\"" . $data[1] . "','" . $data[0] . "'\">" . $text . "</a>";
}
?>
But it gives no error and no display on the screen
[edited by: dreamcatcher at 10:27 am (utc) on Sep. 5, 2007]
[edit reason] Use example.com, thanks. [/edit]
$my_var = str_replace("@", " [at] ", $my_var);
$my_var = str_replace(".", " [dot] ", $my_var);
echo $my_var; // will print: name [at] somedomain [dot] com
i hope this is what you are looking for
[edited by: dreamcatcher at 10:27 am (utc) on Sep. 5, 2007]
[edit reason] Use example.com, thanks. [/edit]