Skip to main content

jQuery Email Address Munging Plugin Released

·1 min

I have released a simple jQuery plugin that converts email addresses such as you [at] example [dot] com into clickable mailto links.

The idea is to allow you to use address munging to fool the many spam bots out there, but provide a clickable link for real users who have JavaScript enabled.

To use it, add the following to your page:

<span class="email">you [at] example [dot] com</span>

Then use the following JS to initialise it:

jQuery(document).ready(function($) {
    $(".email").emailAddressMunging();
});

I use this plugin on my homepage, so hopefully I will be getting a little less spam…

For more information and examples, go to the plugins homepage. The code is available on Github, and is under the MIT license.