/ Published in: JavaScript
URL: http://www.bluewallllc.com
This script stores the elements of the email address as JavaScript variables and assembles them on the fly every time the page loads. The page rendered looks the same to users, but the address never actually lives in the page source code. It can be inserted inline.
Expand |
Embed | Plain Text
<script language=javascript><!-- var email = "kermitthefrog"; var emailHost = "gmail.com"; document.write(email + '@' + emailHost); //--></script> If JavaScript is not working, the visitor will see nothing, though. This will take care of that: <span id="kermit-email">kermitthefrog -at- gmail -dot- com</span> <script language=javascript><!-- var email = "kermitthefrog"; var emailHost = "gmail.com"; document.getElementById('kermit-email').innerHTML = email + '@' + emailHost; //--></script>
Comments
Subscribe to comments
You need to login to post a comment.

Im sorry, but I dont see the point of this lol.
Are you joking? Spam-protecting email addresses is web dev 101. If there's a reason this won't work or doesn't make sense I'd like to know why...specifically.