Here is a PHP function by Ken Butcher based on my ASP function to create an obfuscated mailto. Ken's conversion is also released under a Creative Commons License Attribution-ShareAlike license.
When calling the function, use:
<?=createMailto('[email protected]')?>
This work is licensed under a Creative Commons Attribution-ShareAlike 2.5 License allowing you to use this code on your own site as long as you give proper attribution and include the same license.