	function doform()
	{
		document.Form1.method = "get";
		document.Form1.action = "http://www.google.com/search";				
	}
	
	function getCookie(name)
	 {
		var dc = document.cookie;
		var prefix = name + "=";
		var begin = dc.indexOf("; " + prefix);
		
		if (begin == -1) {
			begin = dc.indexOf(prefix);
			if (begin != 0) return null;
		}
		 else
			begin += 2;
		
		var end = document.cookie.indexOf(";", begin);
		
		if (end == -1)
			end = dc.length;
	
		return unescape(dc.substring(begin + prefix.length, end));
	}
	
	function deleteCookie(name)
	{
		
		if (getCookie(name))
		{
			alert("del");
			document.cookie = name + "=" +		
			"; expires=Thu, 01-Jan-89 00:00:01 GMT";
		}
	}
	
	

	
	function setCookie(name, value) 
	{
		dt = new Date();		
		dt = dt.setDate(120);
		alert(dt.toDateString());

		var curCookie = name + "=" + escape(value) +
			((expires) ? "; expires=" + dt.toGMTString() : "") +
			((path) ? "; path=" + path : "");
		document.cookie = curCookie;
	}


function previewEmail(format)
{
	var URL;
	if(format == 0)
	 URL = "images/sample_text.jpg";
	else
	var URL = "images/sample_html.jpg";
	
	var page = window.open(URL, 'SampleEmail', 'height=400,width=360,status=yes');
}	



function doCounty(countryId)
{
	document.getElementById('dropdCounty').disabled = (countryId != 564);		
}

function ConfirmNewPwrd()
{

	if(document.getElementById('hidEmail').value != document.getElementById('tbxEmailAddress').value && document.getElementById('hidEmail').value.length  > 0)
	{
		return window.confirm("Your email address field has been modified, if you wish to use a new email address, a confirmation email will be sent to\n your new inbox."+
						 "Then you must follow the instructions in the email to re-activate your account with the new address\n"+
						 "Click OK to proceed, or alternatively you can click cancel now and re-name your email address.");			
	}
}



function InitDropDCounty(countyId)
{
	document.getElementById('dropdCounty').disabled = (countyId > 766 && countyId < 799);
}


function DisableEnterKey()
{
	if (window.event.keyCode == 13) 
	{
		event.returnValue=false; 
		event.cancel = true;
	}
}

function fillpassword(pass)
{
	if(pass != null)
	{
		document.getElementById('Password1').value = pass;
		document.getElementById('Password2').value = pass;
	}		
}
	
function RequiredFieldsValidator(source, arguments)
{
	arguments.IsValid = false;
}
 
function GetUserLocation(loc_id, loc_description, loc_parent_id)
{
	this.loc_id = loc_id;
	this.loc_description = loc_description;
	this.loc_parent_id = loc_parent_id;
}
	
//****************************************************************
//Function		:changeLocation
//Date			:25.01.2000
//Author		:Barry Mc Laughlin
//Description	:populate child location select with location details 
//				for the selected parent
//****************************************************************
function changeLocation(form)
	{
	var lLoc_parent_id
	var lDisplayChildCnt = 0	//** number of child locations actually displayed in list
	
	//** find selected parent id
	for (var i=0; i<form.cboParentLocation.length; i++)
		{
		if (form.cboParentLocation.options[i].selected)
			{
			lLoc_parent_id = form.cboParentLocation.options[i].value;
			break;
			}
		}
	
	if (m_lChild_cnt>0)
	{
		//** populate child select box with all locations matching this parent id
		form.cboChildLocation.length=0;
		
		//** add blank item at top of list
		form.cboChildLocation.options[0] = new Option();
		form.cboChildLocation.options[0].value = "";
		
		for (var i=0; i<m_lChild_cnt; i++)
			{
			if (arrChildlocations[i].loc_parent_id==lLoc_parent_id)
				{
				form.cboChildLocation.options[lDisplayChildCnt + 1] = new Option(arrChildlocations[i].loc_description);
				form.cboChildLocation.options[lDisplayChildCnt + 1].value = arrChildlocations[i].loc_id;
				lDisplayChildCnt ++
				}
			}
		
		//** if there are no child locations, hide the select box
		if (lDisplayChildCnt==0)
			{
			//document.all.cboChildLocation.style="hidden"
			}
		}
	}
	
<!--
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v3.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
										
	
		
		
	function GetUserLocation(loc_id, loc_description, loc_parent_id)
	{
		this.loc_id = loc_id;
		this.loc_description = loc_description;
		this.loc_parent_id = loc_parent_id;
	}
	
//****************************************************************
//Function		:changeLocation
//Date			:25.01.2000
//Author		:Barry Mc Laughlin
//Description	:populate child location select with location details 
//				for the selected parent
//****************************************************************
function changeLocation(form)
	{
	var lLoc_parent_id
	var lDisplayChildCnt = 0	//** number of child locations actually displayed in list
	
	//** find selected parent id
	for (var i=0; i<form.cboParentLocation.length; i++)
		{
		if (form.cboParentLocation.options[i].selected)
			{
			lLoc_parent_id = form.cboParentLocation.options[i].value;
			break;
			}
		}
	
	if (m_lChild_cnt>0)
	{
		//** populate child select box with all locations matching this parent id
		form.cboChildLocation.length=0;
		
		//** add blank item at top of list
		form.cboChildLocation.options[0] = new Option();
		form.cboChildLocation.options[0].value = "";
		
		for (var i=0; i<m_lChild_cnt; i++)
			{
			if (arrChildlocations[i].loc_parent_id==lLoc_parent_id)
				{
				form.cboChildLocation.options[lDisplayChildCnt + 1] = new Option(arrChildlocations[i].loc_description);
				form.cboChildLocation.options[lDisplayChildCnt + 1].value = arrChildlocations[i].loc_id;
				lDisplayChildCnt ++
				}
			}
		
		//** if there are no child locations, hide the select box
		if (lDisplayChildCnt==0)
			{
			//document.all.cboChildLocation.style="hidden"
			}
		}
	}

								
<!--
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v3.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->



arrChildlocations = new Array()
var lloc_id
var sloc_desc
var lloc_parent_id
var m_lChild_cnt = 0

//** store an array of child locations in a javascript array


		lloc_id = 773;
		sloc_desc = "Antrim";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 774;
		sloc_desc = "Armagh";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 797;
		sloc_desc = "Carlow";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 776;
		sloc_desc = "Cavan";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 786;
		sloc_desc = "Clare";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 782;
		sloc_desc = "Cork";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 772;
		sloc_desc = "Derry";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 771;
		sloc_desc = "Donegal";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 770;
		sloc_desc = "Down";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 767;
		sloc_desc = "Dublin";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 769;
		sloc_desc = "Fermanagh";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 777;
		sloc_desc = "Galway";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 783;
		sloc_desc = "Kerry";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 792;
		sloc_desc = "Kildare";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 798;
		sloc_desc = "Kilkenny";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 794;
		sloc_desc = "Laois (Queens)";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 781;
		sloc_desc = "Leitrim";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 787;
		sloc_desc = "Limerick";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 791;
		sloc_desc = "Longford";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 789;
		sloc_desc = "Louth";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 778;
		sloc_desc = "Mayo";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 790;
		sloc_desc = "Meath";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 775;
		sloc_desc = "Monaghan";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 799;
		sloc_desc = "Offaly";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 779;
		sloc_desc = "Roscommon";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 780;
		sloc_desc = "Sligo";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 784;
		sloc_desc = "Tipperary";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 768;
		sloc_desc = "Tyrone";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 788;
		sloc_desc = "Waterford";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 795;
		sloc_desc = "Westmeath";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 796;
		sloc_desc = "Wexford";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
	
		lloc_id = 793;
		sloc_desc = "Wicklow";
		lloc_parent_id = 564;
		//** add child location array item
		arrChildlocations[m_lChild_cnt]= new GetUserLocation(lloc_id, sloc_desc, lloc_parent_id);
		m_lChild_cnt +=1 ;
