Email Obfuscator for Octopress
I want to include my email on my blog but I don’t want to store it in plain text - for obvious reasons. Originally I was going to use a third party script to do this since I couldn’t find an Octopress plugin that did what I was looking for.
Instead I decided to write my first Octopress plugin.
The plugin allows the following tag in markdown for obfuscating emails:
1
|
|
This will render a script block that does the following:
- Encodes the
@
and.
characters - Encodes the
mailto:
prefix - Reverses the email and uses CSS to display it to the user
The output from the plugin looks something like:
1 2 3 |
|
I’m currently using the plugin on this blog as of today. Hopefully this is of use to someone else too!