jQuery.fn.emailProt = function(e) { $(this).each(function(){ e = this.rel.replace('|','@'); this.href = 'mailto:' + e; $(this).text(e); }); };
Usage:
$(document).ready(function(){ $('.email').emailProt(); });
<a rel="user|stylephreak.com" class="email"></a>