=== HumansNotBots - Easy, Accessible Email Cloaker === Contributors: zingming Tags: email, spam, email obfuscator, email munger, email obfuscation, email munging, email cloaker, accessibility, post Requires at least: 3.0.1 Tested up to: 3.0.1 Stable tag: 1.0 "email AT address DOT com" (without quotes) is converted to a clickable version of email@address.com if JavaScript is enabled. == Description == This email cloaking method: * is accessible for people browsing with screen readers (e.g., blind people); * degrades gracefully for browsers without JavaScript; * works just like a normal, clickable email address for browsers with JavaScript enabled; and * requires no shortcodes. Email addresses in the form `email AT address DOT com` are converted to a clickable version, [email@address.com](mailto:email@address.com), if JavaScript is enabled. If JavaScript is not enabled (such as for screen readers), then the email address in the form `email AT address DOT com` is still readable to humans. == Installation == Unzip the zip file into the `/wp-content/plugins/` directory. Activate the plugin through the 'Plugins' menu in WordPress. == Frequently Asked Questions == = Won't email scrapers figure out email addresses in the form `email AT address DOT com`? = In a test comparing the [effectiveness of different obfuscation methods](http://techblog.tilllate.com/2008/07/20/ten-methods-to-obfuscate-e-mail-addresses-compared/) in 2008, the obfuscation method "Using ATs and DOTs" received much less spam than "Replacing @ and . with Entities". Assuming that the 2008 test is an accurate model, this plugin should reduce over 99% of spam without compromising accessibility. "CSS display: none" should *not* be used, because screen readers cannot read content styled with `display: none` either. Reversing email addresses and using ROT-13 encryption are obviously not accessible, either. == Screenshots == 1. Compose posts with email addresses in the form `email AT address DOT com`. 2. The post should show a clickable email address. 3. If you view the HTML source, the email scraping bots can only see `email AT address DOT com`. == Code == humansnotbots.php `' . "\n"; } function addToBodyTag () { echo 'onload="HumansNotBots()" id="htmlbody" '; } } $humansnotbots = new HumansNotBots(); add_action('wp_head', array($humansnotbots, 'addToHead')); add_action('body_class', array($humansnotbots, 'addToBodyTag')); ?>` humansnotbots.js `function HumansNotBots() { var htmlbody = document.getElementById('htmlbody'); var rep = '$1@$2.$3'; var newInnerHTML = htmlbody.innerHTML.replace(/([a-zA-Z0-9._%+-]+)\sAT\s([a-zA-Z0-9.-]+)\sDOT\s([a-zA-Z]{2,4})/g, rep); htmlbody.innerHTML = newInnerHTML; }`