	/* =======================================================
	Author:         Chris Toby
	Date:           21/10/04              
	Description:    fn to write mailto links, hides email address from page source
	Parameters received: 
		String emailName - the segment of the address prior to the '@'
		String emailDomain - the segment of the address after the '@'
		String displayName - the displayname, if not the email address
	Parameters returned: 	
		String - mailto link in html	
	Modification history: 
    =======================================================*/	
	function writeMailto(emailName, emailDomain, displayName){
		// if the displayName param is not provided then use the email address 
		if (displayName == null || displayName == 'undefined' || displayName == ""){
			displayName = emailName;
			displayName += "@";
			displayName += emailDomain;
		}
		var str = "";
		str = "<a href='mailto:";
		str += emailName;
		str += "@";
		str += emailDomain;
		str += "'>" + displayName + "</a>";
		document.write(str);
	}	

	/* =======================================================
	Author:         Reuben Rowe
	Date:           05/09/05              
	Description:    fn to write mailto links, hides email address from page source
	Parameters received: 
		String emailName - the segment of the address prior to the '@'
		String emailDomain - the segment of the address after the '@'
		String displayName - the displayname, if not the email address
		String cssClassName - the css class to assign to the <a> element
	Parameters returned: 	
		String - mailto link in html	
	Modification history: 
    =======================================================*/	
	function writeMailto(emailName, emailDomain, displayName, cssClassName){
		// if the displayName param is not provided then use the email address 
		if (displayName == null || displayName == 'undefined' || displayName == ""){
			displayName = emailName;
			displayName += "@";
			displayName += emailDomain;
		}
		var str = "";
		str = "<a href='mailto:";
		str += emailName;
		str += "@";
		str += emailDomain;
		str += "'";
		str += " class='" + cssClassName + "'>" + displayName + "</a>";
		document.write(str);
	}