<!-- Begin
function ConfDel(){
return confirm('UNWIEDERRUFLICH L Ö S C H E N?')
}
function ConfAction(confmsg){
return confirm(confmsg)
}

function autocheck(obj){
	fname = obj.form.name;
	text_name = obj.name;
	check_name = text_name.replace("Text","");
	
	document.forms[fname].elements[check_name].checked=true;
}

function region2(obj, state_field){ 
	name = obj.form.name;
	nr=obj.selectedIndex;

	while(document.forms[name][state_field].length>1){ 
		document.forms[name][state_field].options[document.forms[name][state_field].length-1]=null;
	} 
	for(i=0;i<beschriftung[nr].length-1;i=i+2){ 
		x=new Option(beschriftung[nr][i],beschriftung[nr][i+1]) ;
		document.forms[name][state_field].options[document.forms[name][state_field].length]=x;
	} 
	document.forms[name][state_field].selectedIndex=0;
}

function no_price(){
	if(document.forms['Setup'].elements['NoPrice'].checked==true){
		document.getElementById('PriceData').style.display = 'none';
		h = '0px';
	}else{
		document.getElementById('PriceData').style.display = 'inline';
		h = '100%';
	}
	//document.getElementById('PriceData').style.height = h;
}

function season_year(dropnr){
	for(i=0; i<document.Setup.SeasonYear.length; i++){
    	if(document.Setup.SeasonYear[i].checked == true){
			if(document.Setup.SeasonYear[i].value == 'Y'){
				deaktiviert = false;
			}else{
				deaktiviert = true;
			}
		}
	}
	for(i=1; i<=24; i++){
		if(document.forms['Setup'].elements['StartYear'+i]){
			document.forms['Setup'].elements['StartYear'+i].disabled=deaktiviert;
			document.forms['Setup'].elements['StartYear'+i].selectedIndex=0;
		}
	}
	
}

function res_season(dropnr){ 
	document.forms['Setup'].elements['StartDay'+dropnr].selectedIndex=0; 
	document.forms['Setup'].elements['StartMonth'+dropnr].selectedIndex=0;
	document.forms['Setup'].elements['StartYear'+dropnr].selectedIndex=0;
	document.forms['Setup'].elements['EndDay'+dropnr].selectedIndex=0;
	document.forms['Setup'].elements['EndMonth'+dropnr].selectedIndex=0; 
	document.forms['Setup'].elements['SeasonPrice'+dropnr].value=''; 
}

function general_item(gitem,stat){ 
	document.forms['Setup'].elements['GeneralItem'+gitem][stat].checked=true;
	if(gitem == 4 && stat == 1){
		document.forms['Setup'].elements['PetsOnRequest'].checked=false;
	}
	if(gitem == 'CP' && stat == 1){
		document.forms['Setup'].elements['Carparks'].selectedIndex=0;
	}
}

function pets_request(){
	if(document.forms['Setup'].elements['PetsOnRequest'].checked==true){
		general_item(4,0);
	}
}

function carparks(){
	if(document.forms['Setup'].elements['Carparks'].value > 0){
		document.forms['Setup'].elements['GeneralItemCP'][0].checked=true;
	}
}
function pricemodel(radio){
	if(radio != 'Week_Person'){
		document.forms['Setup'].elements['PersonPerWeek'].selectedIndex=0;
	}
	if(radio != 'Day_Person'){
		document.forms['Setup'].elements['PersonPerDay'].selectedIndex=0;
	}
}

function textCounter(field, countfield, maxlimit) {
	// if too long...trim it!
	if (field.value.length > maxlimit)
	// otherwise, update 'characters left' counter
	field.value = field.value.substring(0, maxlimit);
	else
	countfield.value = maxlimit - field.value.length;
}

function schreiben(obj)
{
nr=obj.selectedIndex;
document.forms['Address'].Dialling1.value=beschriftung[nr];
document.forms['Address'].Dialling2.value=beschriftung[nr];
document.forms['Address'].Dialling3.value=beschriftung[nr];
document.forms['Address'].Dialling4.value=beschriftung[nr];
document.forms['Address'].Dialling5.value=beschriftung[nr];
}

function CopyRegister(zip,vil) {
opener.document.forms['Setup'].ObjectZip.value = zip;
opener.document.forms['Setup'].VillageNew.value = vil;
window.close();
}

function CopyAddress(obj){
	var name = obj.form.name;
	document.forms[name].ContactFirm.value = document.forms[name].Firm.value;	
	document.forms[name].ContactGender.value = document.forms[name].Gender.value;
	document.forms[name].ContactName.value = document.forms[name].Name.value;
	document.forms[name].ContactFirstName.value = document.forms[name].FirstName.value;
	document.forms[name].ContactStreet.value = document.forms[name].Street.value;
	
	if(document.forms[name].ContactStreet2 && document.forms[name].Street2){
		document.forms[name].ContactStreet2.value = document.forms[name].Street2.value;
	}
	document.forms[name].ContactZip.value = document.forms[name].Zip.value;
	document.forms[name].ContactCity.value = document.forms[name].City.value;
	document.forms[name].ContactPhone.value = document.forms[name].Phone.value;
	document.forms[name].ContactFax.value = document.forms[name].Fax.value;
	document.forms[name].ContacteMail.value = document.forms[name].eMail.value;
	document.forms[name].ContactNatel.value = document.forms[name].Natel.value;

	//if(document.forms[name].ContactStateID && document.forms[name].StateID){
	//	document.forms[name].ContactStateID.value = document.forms[name].StateID.value;
	//}
	document.forms[name].ContactCountryID.value = document.forms[name].CountryID.value;

	address_mng(document.forms[name]['ContactCountryID'], '', document.forms[name].StateID.value);
}

Fensterzahl=0
function help(mypage, myname, w, h, scroll, menu){
	var winl = (screen.width - w) / 2;
	var wint = (screen.height - h) / 2;
	if(Fensterzahl>0){
		if(F1.closed==false)
		F1.close()
	}
winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',menubar='+menu+',resizable'
F1=window.open(mypage, myname, winprops)
F1.focus()
Fensterzahl=1
}

function fensterzu(){
	if(Fensterzahl>0){
		if(F1.closed==false)
		F1.close()
	}
}
// End -->
