In the following sample, cut and paste it into your web page, then substitute the appropriate replacements for First-name, Last-name, username, and host.com.
<script language=javascript> var fullName = "First-name Last-name" var user = "username" var domain = "host.com" var address = user + "@" + domain var linkStart = "<a href=" + "mail" + "to:" + address + ">" var linkEnd = "</a>" var linkName = linkStart + fullName + linkEnd var linkAddress = linkStart + address + linkEnd document.write(linkName + " " + "<" + linkAddress + ">") </script>The above JavaScript displays the following in a browser as: