function showHide(show,element) {
	var element = document.getElementById(element);
	if (show) {
		element.style.display = '';
	}
	else {
		element.style.display = 'none';
	}
}

function UpdatePhone() 
{
	var txtFirstNum = document.getElementById('phone1');
	var txtSecondNum = document.getElementById('phone2');
	var txtThirdNum = document.getElementById('phone3');
	var txtFullPhone = document.getElementById('phone_day');
	
	var fullPhone = txtFirstNum.value;
	if (txtFirstNum.value.length>0)
	{
		fullPhone += '';
	}
	
	fullPhone += txtSecondNum.value;
	
	if (txtSecondNum.value.length>0)
	{
		fullPhone += '';
	}
		
	fullPhone += txtThirdNum.value;
	
	txtFullPhone.value = fullPhone;
}	

function UpdateCell() 
{
	var txtFirstNum = document.getElementById('cell1');
	var txtSecondNum = document.getElementById('cell2');
	var txtThirdNum = document.getElementById('cell3');
	var txtFullCell = document.getElementById('phone_eve');
	
	var fullCell = txtFirstNum.value;
	if (txtFirstNum.value.length>0)
	{
		fullCell += '';
	}
	
	fullCell += txtSecondNum.value;
	
	if (txtSecondNum.value.length>0)
	{
		fullCell += '';
	}
		
	fullCell += txtThirdNum.value;
	
	txtFullCell.value = fullCell;
}	


function show_help() {
	showHide(true,'help_callout');
}
function hide_help() {
	showHide(false,'help_callout');
}

function show_anotherFriend() {
	showHide(true,'friendForm2');
}
function hide_anotherFriend() {
	showHide(false,'friendForm2');
}


function autotab(original,destination){
if (original.getAttribute&&original.value.length==original.getAttribute("maxlength"))
destination.focus();
}



