Codex tools: Log in
Contents |
Converts email addresses characters to HTML entities to block spam bots.
<?php antispambot( $emailaddy, $mailto ) ?>
<?php
echo antispambot("john.doe@mysite.com");
?>
This will output the email like this in the HTML:
john.doe@mysite.com
And in their browser, people will still see it right:
john.doe@mysite.com
Since: 0.71
antispambot() is located in wp-includes/formatting.php.