/*
 * the mailtobit script
 * put here so it can be shared and cached, speeding things up. 
 * JSS 22 Sept 2003
 * eg of what to put in the header:
 <script language=javascript src="rw_library/rw_mailbit.js"></SCRIPT>
 * eg of call (note if you leave the last param "", it displays the email address instead)
 * 
  <script language=javascript>
	<!--
	 mailtoBit("info", "reefwatch.asn.au", "Reefwatch Information");
	//-->
  </script>
*/

// The mailtoTag() function is used to hide the mailto: tags from spambots.
//   frontbit        = username part of address
//   backbit      = domain part of address
//   webbit = optional text to display on the page instead of the
//                 email address.
// Based on "SpamProof Mail Script 1.0 by Joseph McLean <flux@thecentre.com>"
// parameter names modified to frustrate the bots
  function mailtoBit(frontbit, backbit, webbit) {
     document.write("<a href=" + "mail" + "to:" + frontbit + "@" + backbit + ">");
     if (mailtoBit.arguments.length > 2)
        document.write(webbit + "</a>")
     else
        document.write(frontbit + "@" + backbit + "</a>");
  }


